Search:

Type: Posts; User: 54stickers

Search: Search took 0.34 seconds.

  1. Re: Counting the amount of zeroes, odd and even numbers in an integer

    Comparing it to '0' worked this time... I tried that earlier, but the code didn't compile.

    Thanks!
  2. Counting the amount of zeroes, odd and even numbers in an integer

    public class NumSearch {

    public static void main(String[] args) {
    Scanner scan = new Scanner(System.in);
    int input;
    int i=0,g=0,f=0;
    int even = 0;
    int odd = 0;
    int zero = 0;...
Results 1 to 2 of 2