Java Blog

 
 
 
 public class JAVA_016
 {


    public static void main(String[] args)
    {
       int number=(int)(100*Math.random( ));

       if((number%2)==0)
          System.out.println(\"The Random Number Generated (0-99) is Even : \" + number);

       else
          System.out.println(\"The Random Number Generated (0-99) is Odd : \" + number);
    }
 }

    Related Post:
  1. An applet program that display blinking rectangle

  2. Corba program of date operations

  3. Program to show an example of creating a class and using its object

  4. Program for calculating area of a circle on server side,when a client sends request along with given radius and then displaying result on client side

  5. RMI servlet program to display message

  6. Application for counting factorial of a given number

  7. Program sets up a String variable containing a paragraph of text of your choice. Extract the words from the text and sort them into alphabetical order

  8. An applet program to display sum of two number of textField

  9. Develop a simple calculator with addition, subtraction, multiplication and division capabilities, data collection from client side, executed on server

  10. An applet program of linear sort

  11. Program to show an example of creating String objects from Character Arrays

  12. Program to compute the sum of the digits of a given integer number. eg: I/o=4 then O/p=4+3+2+1=10

  13. Program to show the use of Bitwise Operator (^) XOR (Exclusive OR)

  14. Program to show an example of creating Character Arrays from String objects

  15. Servlet which takes input from an HTML client page and calculates and outputs the premium amount

  16. An applet program to find maximum of three numbers using textField

  17. Program to ask question and accept answer up to 3 attempt and display right answer if it is wrong

  18. Program to read rollno, marks of sub1,sub2 and sub3 and on basis of that display result

  19. Encrypt the text that you want to send on the client side. The server side decrypts it after receiving. Append server time after each word in the sent

  20. Corba program to encrypt the text that you want to send on the client side. The server side decrypts it after receiving. Append server time.

 
 
Didn't find what you were looking for? Find more on Program to show the use of If-Else Statement