APCS Blog Post August 22


Successes in this class:

I was able to create a dynamic variable area calculator that could accurately print the area for rectangles, triangles, and circles. This I think was a big step in grasping java, as I now know how to call methods and can set and use method parameters to create more intricate projects. In addition I think my ability to dynamically decide what shape and dimensions I wanted was a big accomplishment compared to a lot of others who I saw hardcoding their dimensions into their programs.

Different data types in java:

  1. Boolean
    1. Booleans are true or false values. They can either be true or false.
  2. Integer
    1. Integers are whole numbers.
  3. Double
    1. Double values are double-prescision 64 bit values. I’m not totally sure what that means but it is the standard when storing decimal values.
  4. Float
    1. Floats are single-precision 64 bit values. These are more lightweight however are not as precise as double, so they are more often used for mass, low priority, data storage.

APCS Blog Post August 21

In class today I learned a few important things:

  1. First I learned how to use the BlueJ IDE. I used it to create the two classes DiffPhrases and HelloWorld
  2. Second I learned how to set up a main method and print using Java. I am more comfortable using python as I’ve used it for a lot longer however this HelloWorld class was a good start to learning Java.
  3. Third and possibly the most importantly I learned the syntax for using a for loop in Java. I used this in my DiffPhrases function to print each argument passed when calling it. This loop can be seen below:
public class DiffPhrases{
  public static void main(String[] args){
    for (int i=0; i < args.length; i++){