Bronze Classes‎ > ‎

Essentials Assignments

Summer 2015 - Final Assignments!

posted Aug 14, 2015, 7:13 PM by Attila Lengyel

These summer classes were awesome, and we learned quite a bit about the basic of programming, from creating variables to for loops!

The final topic was debugging, an important skill in every programmer's toolkit. This is how we determine what went wrong in our program, or why the computer couldn't compile our program.

Similar to the class session, the first two assignments are programs that won't quite work. Copy the code into a file on your Koding profile and try to get it to run.
The last assignment is what was given in class, an Easy and Challenge program that you must write from scratch.

Good Luck, and Happy Coding!

Summer 2015 - Lesson 7 Assignments

posted Aug 9, 2015, 12:41 PM by Attila Lengyel

This lesson introduced us to the while loops, which are similar to for loops but with a slightly different structure. We were able to use them to have the computer repeat a process while we had input to give it.
We also explored the comparison compounders, which allow us to combine comparison in one line. These are the AND and OR operators, which in Java are written as && and ||.

For the assignments 1 and 2, the code will seem similar to what was covered in class. Try to complete these assignments without looking at your previous work.
Assignment 3 is a little trickier, and give you less to go on. You will be writing a program which creates a Collatz Sequence, which takes any number given and performs an algorithm it reaches 1. You can find more information here.

Summer 2015 - Lesson 6 Assignments

posted Jul 31, 2015, 8:37 PM by Attila Lengyel   [ updated Jul 31, 2015, 8:44 PM ]

This lesson, we reviewed the syntax of our for loops, a very important piece of programming. We also were introduced to a new tool, the Scanner.

Recall that the for loop is made of three parts, the starting declaration (telling the computer what number to start at), the ending condition (when the condition is false, stop looping), and the step increment (how the loop counts sequentially).
The Scanner allows us to ask the user for input from the user while the program is running. We do this by importing the Scanner object using the line import java.util.Scanner; , creating a Scanner object in main, and then using it to read input.

Assignment 1 will be more of a review of for loops. The code for creating and using a Scanner object has been provided, so study it for use later.
Assignment 2 will ask you to create a Scanner object, and use it to ask the user for TWO numbers. The program will then multiple the two of them, and display the result.
Assignment 3 will introduce a new function of the Scanner, the ability to read a complete line of text from the user. If you are able to complete the program properly, you should be able to provide a number and a string of text, which the computer will repeat as many times as you requested.
Good Luck!

Summer 2015 - Lesson 5 Assignments

posted Jul 24, 2015, 8:52 PM by Attila Lengyel

This lesson, we learned one of the most crucial parts of programming; how to use a for loop.

The for loop is the way we get the computer to do lots of cool things that would take us ages to get done, like printing out the numbers from 1 to 100, or 1 to 1000.

The included assignments will be similar to what we were able to get done in class.
Assignment 1 is very similar to the activity in class in which we had the loop sum the numbers between X and Y (where X and Y are numbers we gave the computer).
Assignment 2 will require you to use your knowledge of if statements and the modulus operator. If you've never heard of the modulus operator, try reading this article on what a Remainder in division is. The modulus operator returns the remainder of a division operation.

Summer 2015 - Lesson 4 Assignments

posted Jul 13, 2015, 6:53 AM by Attila Lengyel

This lesson was a review of what we had learned previously about variable assignment and conditional statements.

We also played a fun game, which we hope helped you understand how a computer is only able to follow a sequence of instructions, and does not have the intelligence we assume humans do. This is an important concept to understand, as we must become skilled programmers, able to understand when we might be telling the computer the wrong thing.

Summer 2015 - Lesson 3 Assignments

posted Jul 2, 2015, 5:47 PM by Attila Lengyel

During this lesson, we covered some of the basic of conditional statements in Java programming. We also talked the different comparison operators we can use.

With regards to conditional statements, we covered the generic syntax of conditional statements and the if-then-else statement.
We also learned about the many different comparison operators, like the "equal to" sign, or the "not equal to" sign.

On this post, you will find three programming assignments.
Assignment 1 is a very basic exercise, which you should be able to copy into a file and run. However, before running the file, you should first determine what the output of the file will be.
Assignment 2 also provides you a large amount of code, but in this case, you will need to change the values of a few variables.
Assignment 3 is a bit more empty, asking you to provided the conditions for some if-then-else statements, and write an if-then-else statement from scratch.
Good Luck!

Summer 2015 - Lesson 2 Assignments

posted Jul 1, 2015, 5:03 PM by Attila Lengyel   [ updated Jul 1, 2015, 5:04 PM ]

During this lesson, we covered some of the basic of variables in Java programming. We also talked about some general ideas of what programs are, and explained some rules about writing programs in Java.

We learned how variables are like boxes, which hold a value. Each variable is given a specific name, that follows strict naming conventions.
We learned that programs are essential data being changed by algorithms, or sequences of instructions.
We also learned about the important of curly brackets (aka., curly braces) and semicolons. Remember, semicolons are the periods to our programming sentences.

On this post, you will find two programming assignments.
Assignment 1 shows you how a variable is created and then printed out. You must then re-assign the values of the variables created to print out new information.
Assignment 2 asks you to create two new variables (a new int and a new String), and then figure out how to swap the values of the same type.
Good Luck!

1-7 of 7