Eager to Code, Enjoy to Debug ~ Embark into Each Stage with Your Heart

Archive for October 21st, 2008

Chapter 5: Control Statements Part II (Exercise 5.15)

Posted by: Chyne on: October 21, 2008

/* Exercise 5.15
* 1. Displays graphs and bar charts.
* 2. Reads 5 numbers between 1 and 30.
* 3. Display the same number of adjacent asterisks for each number.
*/
package Exercises;
import java.util.Scanner;
public class BarCharts {
public static void main(String[] args) {
int value = 0;      // temporary value
int numCounter; // number of input entered
int num = [...]


Friday’s Java Snack


In Java, "thread" means:

  • An instance of class java.lang.Thread
  • A thread of execution


An instance of Thread is just an object that has variables and methods, and lives and dies on the heap.
 
A thread of execution is an individual process that has its own call stack (one thread per call stack).

 

October 2008
M T W T F S S
« Sep   Nov »
 12345
6789101112
13141516171819
20212223242526
2728293031  

Archives


StatCounter

free hit counters