jpr practical
jpr practical
19. Write a java program to display all the odd numbers between 1 to 30 using for loop
& if statement.
20. Develop a Program to import different classes in package.
21. Write a program to create an applet to display message. “Welcome to java applet”.
22. Create three threads and run these threads according to set priority
23. Write a program to create two threads, one to print numbers in original order and
other in reverse order from 1 to 10.
24. WAP to accept a password from the user & throw “Authentication failure ”
exception if the password is incorrect.
25. Develop a program to throw a user defined exception if the given number is not
positive.
26. Write program that Define an exception called "No match Exception‟ that is
thrown when a string is not equal to “MSBTE”.
27. Develop a program to create two threads such that one threads displays the message
“How do you do?” and the other thread displays the message “Fine, Thank you!”
28. Write the applet program to draw square inside circle.
29. Write an applet program to draw rectangle which is filled with red color.
30. Develop a program to copy the contents of the file “abc.txt” into a new file “xyz.txt”.