Posts

Showing posts from December, 2016

Applet Polygon Co ordinates

Image

How to run applet in ubuntu or linux

Image
After import statement just add this line in your applet /*<applet code ="appletwelcome" width=100 height =300></applet>*/ Here is the sample applet source code //Applet displaying welcome import java.applet.*; import java.awt.*; /*<applet code ="appletwelcome" width=100 height =300></applet>*/ public class appletwelcome extends Applet {     public void init()      {           setBackground(Color.red);       } public void paint(Graphics g) {      String msg="welcome";      g.drawString(msg,10,10); } }

How to run java applet program in windows

Image

How to set java path in windows

Image

cmd- change to another drive? in command prompt

you want to change int othe E: drive at command prompt? type the below at the C:\> prompt: E: That's all! When in windows, you want to open the drive in explorer, type the same as above into the "Run" box or  address bar. http://www.wikihow.com/Change-Directories-in-Command-Prompt dir  - This command will list all of the folders and files in the directory you are currently at. cd  folder  - This command will move you to the folder that you specify. The folder must be in the directory you are currently in. For example: If you are currently at  C:\Users\ username \  and you enter  cd desktop  you will be taken to  C:\Users\ username \Desktop\ cd  path  - This command will take you to a specific path on your computer. You do not need to be in the same directory as the path. You must enter the entire path for it to work. For example:  cd C:\Windows\System32 cd ..  - This command will move you up one...

java programs

Image
Java program to check whether string is palindrome or not Posted on   September 21, 2013 by   Anuroop D In earlier post we have discussed how to check whether a  number is palindrome or not .In today’s post we shall check whether a string is palindrome or not.For this we shall use built in functions to reverse a string and then compare the reversal of string to given string. Procedure: 1. Take input from the user and store it in a variable. 2.Here we are going to call a function “reveresing” to find the reverse of the string. 3.At last we shall call the display function to show whether it is a palindrome or not. Now we shall write a program and get a detailed explanation after this. 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 import java.util.*; class finding {     String str,reverse_str= "" ; ...