Array Lab
Array Lab

Everyone will mostly be working gloriously alone today.

I would suggest you work only from your book and personal notes.

Try not to ask your neighbor for help with practice clients in parts 1&2 -- they should be easy!

Required Working Style for Today's Lab:

  • From beginning to end you will work in a folder which contains all your work for today's lab.

  • Before you leave, you will email me all the files necessary to run your application.

  1. Do these if you need more practice with exercises like ArrayPracticeClient.java from last week. Work one or both of these similarly by filling in the necessary code below each comment provided. Use Scanner  

  2. Write a client that will use a scanner to talk to a user. User will enter an integer providing the size of a numerical pattern. If size is greater than 2 and less than 10. Tree should be 'upright' for odd values; upside down for even
            java TreeClient 
                 How high should tree be [3,9]:  7
    
            1
            22
            333
            4444
            55555
            666666
            7777777
             
    
    
            java TreeClient 
                 How high should tree be [3,9]:  6
    
            666666
            55555
            4444
            333
            22
            1
             
    
    
     


  3. Reverse engineer the following so your's is EXACTLY WORKING like this one.

    APClient4.class


  4. Your ideas from this morning...

    1. Take an array of various strings and print various stats such as average length of word or number of vowels.

    2. Loop that generates first 100 digits of PI

    3. Can you use them to find when an object will end up if given a vector?

    4. Use a loop to make a program that prints out a string into morse code (*,_)

    5. Make a loop that prints an average of even arrays given on the command line a number of times also given on command line. ???

    6. Have an array of strings and use a loop to only print the words with 5 characters.

    7. Use a loop and array to find mean, median, range.

    8. Prove Halloween is the same as Christmas?

    9. Construct a while loop with an array that prints the square root of a number. ???