2022-08-29

Prep for II.2
  1. Make this list with less work:

     [26,25,24,23,22,21,20,19,18,17,16,15,14,
     13,12,11,10,9,8,7,6,5,4,3,2,1]
    
  2. Make this string with less work:

     "abcdefghij"
    
  3. How do you make a list that starts [8,8,8,8,8 and then goes on forever.

  4. What is the signature of the function you used in the previous question?

  5. What is the difference between cycle and repeat?

    Possible signature: cycle :: [Int] -> [Int]

    Example: cycle [8,9,11] == ?

  6. Write an example showing an equality between cycle applied to something and repeat applied to something.

     cycle __________ == repeat __________
    
  7. How do you get the following? Would that change if there were fifty 2’s instead of five?

     [2,2,2,2,2]
    
  8. Make this list:

     [(1,10),(2,20),(3,30),(4,40) ... up to ... (9,90)]
    
  9. Make this list:

     [(2,23), (2,24), (2,25), (3,23), (3,24), (3,25),
     keep going all the way to (13,23), (13,24), (13,25)]
    
  10. Make this list:

    n10 = [(2,23), (3,24), (4,25), ... go until ... (50,71)]
    
  11. Find all of the ordered pairs (x,y) from the list n10 above that have y>x*x.

Last modified August 18, 2023: 2022-2023 End State (7352e87)