Full Range

Call me (USA Free)

Monday, 14 April 2014

String programs.....

1 comment
Q.Write a java program to count the number of words in the entered sentence  import java.io.*; public class CountWords {   public static void main(String args[])throws Exception     {        BufferedReader stdin =new BufferedReader(new InputStreamReader(System.in));        System.out.print("Enter the sentence: ");        String s=stdin.readLine();        s=' '+s;        char ch;        int...
Read More

Printing Patterns....

Leave a Comment
Q.Write a program to print the following pattern        *      * *      * * *      * * * *      * * * * *        public class HalfTriangle  {      public void pattern(int n)       {           for(int i=1;i<=n;i++) //to define the number of rows             {               for(int j=1;j<=i;j++)  ...
Read More

Simple programs for beginner's

Leave a Comment
Q.Write a java program to add two numbers.      public class  addNum     {         public void sum(int x,int y) // creates the instance of a class        {                int z=x+y;            System.out.print(z);        }      }     Q.Write a java program to subtract two numbers.       public class Difference    ...
Read More
Leave a Comment
This blog is mainly a guide for isc computer science students...Some solved questions are given in this blog and also guidance to java progaram....icse students can also refer to this site for learning programs...
Read More