1 / 32

Exam 2 Review Game

Exam 2 Review Game. CSC 111. Individual Round. 1. What does the code do? x = x + dx; y = y + dy ;. 2. What does the code do? dx = dx * -1;. 3. What does the code do? dy = dy + 1;. 4. What does the code do? int [] numbers = new int [5];. 5. Suppose numbers is [10, 20, 30]

nirav
Download Presentation

Exam 2 Review Game

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Exam 2 Review Game CSC 111

  2. Individual Round

  3. 1. • What does the code do? x = x + dx; y = y + dy;

  4. 2. What does the code do? dx = dx * -1;

  5. 3. • What does the code do? dy = dy + 1;

  6. 4. • What does the code do? int[] numbers = new int[5];

  7. 5. • Suppose numbers is [10, 20, 30] • What is printed? for (inti = 0; i< numbers.length; i++){ println(i); }

  8. 6. • Suppose numbers is [10, 20, 30] • What is printed? for (inti = 0; i< numbers.length; i++){ println(numbers[i]/10); }

  9. 7. • Suppose numbers is [10, 20, 30] • What is printed? for (inti = 0; i< numbers.length; i++){ if(numbers[i] > 20){ println(numbers[i]); } }

  10. 8. • What is printed? int max = 5; for (inti = 1; i<= max; i++){ println(i); }

  11. 9. • What is Moore’s law?

  12. 10. • The brains of the computer, usually a single-chip microprocessor

  13. 11. • The circuitry of the main components of the computer, including the CPU, RAM, ROM, and slots for cards

  14. 12. • The part of memory that is completely erased when the power is off.

  15. 13. • The part of memory that is the fastest – it’s inside the CPU.

  16. 14. • One part of a hard drive – has sectors and tracks

  17. 15. • The memory that holds the boot-up program

  18. 16. • Term that includes disk drives, printers, jump drives, screen, keyboard, and mouse

  19. 17. • How data is transmitted from one part of the machine to another

  20. 18. • Who is the Yale professor who created the “grand principles” of visualizations?

  21. 19. • Name any 2 of Tufte’s Grand Principles of visualization

  22. 20. • How can graphs lie (assuming the data is accurate) ?

  23. 21. • Excessive, decorative elements in a visualization that serve no purpose with the data

  24. 22. • What’s the difference between a .csv and a .tsv file?

  25. 23. • What is the process of finding intermediate, unknown values in between known values?

  26. 24. • The map command is: map(origValue, origMin, origMax, newMin, newMax); • float score = map(2, 1, 10, 1, 100); • What is the value of score?

  27. 25. • What does the lerpColor command do?

  28. Team Round

  29. Processing • Write a loop that will draw 10 circles, all at different random places on the (500,500) screen

  30. Processing • Write a loop that will draw 10 circles, all at different random places on the (500,500) screen for(inti =1; i<= 10; i++){ float x = random(0,500); float y = random(0,500); ellipse(x,y,20,20); }

  31. HARDWARE • Put in order from slowest memory to fastest: • Cache • Hard drive • Camera (plugged into computer through USB) • RAM • Registers

  32. VISUALIZATIONS

More Related