Skip to content

Cruziken/CruzikenWork

Repository files navigation

Exercises

Exercise 1

Print "Hello World!"
Associated file: Excercise1.java

Exercise 2

Print "Hello World!" and get user input from Command Line.
Associated file: Exercise2.java

Exercise 3

Print "Hello World!", get user input of filename, read the file, and print the contents.
Associated file: Exercise3.java

Exercise 4

Print "Hello World!", get user input of filename, read the file, print the content, and copy the contents to another file.
Associated file: Exercise4.java

Exercise 5

Basically Exercise 4 but with classes (introduces OO concepts).
Associated files: Excersise5.java, PromptnPrint.java, Screamers.java, Copiers.java, Interfacer.java

Exercise 6 (FizzBuzz with OO concepts)

Step 1:

Read off an INI file with the following format:

  • max_int (In this case key value is) = 100
  • lower_divisor (In this case key value is) = 3
  • upper_divisor (In this case key value is) = 5
  • lower_divisor_label (In this case key value is) = fizz
  • upper_divisor_label (In this case key value is) = buzz

Step 2:

Print the integers 1-max_int, unless...
  • If the integer is divisible by lower_divisor, print lower_divisor_label instead of the integer.
  • If the integer is divisible by upper_divisor, print upper_divisor_label instead.
  • If it is divisible by both lower_divisor and upper_divisor, print lower_divisor_label+upper_divisor_label.

Step 3:

In addition to printing the output, store it in a log file named log_.text

Associated files: GenericFizzBuzz.java, LogicController.java, INIfileLoader.java, Writer.java, Variables.java, and AbsolutePath.java.

About

The work of The Coding Apprentice

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages