0 Members and 1 Guest are viewing this topic.
{1,2,3,4,5,6,7,8,9,0->L120->S //We set the shift to 20. If it goes negative, bad things happen :P"1+10fPart((X+S)/10->Y1 //This is our magic formula, using modulus arithmetic, it gives us //the element we want but accounts for the shift //It is stored to Y1 for easy use :PWhile 1 For(F,1,10 //Just some simple code to display the list from 'start' to 'finish' Output(1,F,L1(Y1(F //But using the formula, so in perspective of the shiftEndRepeat AnsgetKey -> KEndS + (K=24) - (k=26) //You can change the shift with your arrow keysEnd
Oh, ok, i see what you're saying. This would be amazing and exactly what i need... except that i cant have it wrap
{1,2,3,4,5,6,7,8,9,0->L10->S "1+10fPart((X+S)/10->Y1 //yay magic formula While 1 For(F,1,10 //Display the entire linked list so you can see whats going onOutput(1,F,L1(Y1(F //Displays elements from 1 to 10Endrand(20S+1->S //Increase shiftrandInt(0,9->L1(Y1(10 //Add random number onto the 'end' of the list, which is element 10End