Latest Tutorials| Questions and Answers|Ask Questions?|Site Map



Home Answers Viewqa Java-Beginners how to print the following pattern

Have Programming Question? Ask it here!
 
 
 


Asma Ahmed
how to print the following pattern
1 Answer(s)      2 years and 10 months ago
Posted in : Java Beginners


Hello hEllo heLlo helLo hellO

pls reply soon its an emergency


Advertisement
View Answers

October 28, 2011 at 11:08 AM


class StringPattern
{
    public static void main(String[] args) 
    {

        String st="hello";
        StringBuffer buffer=new StringBuffer(st);
        for(int i=0;i<st.length();i++){
            char ch=Character.toUpperCase(st.charAt(i));
            String str=buffer.replace(i,i+1,Character.toString(ch)).toString();
            System.out.println(str);
            buffer.replace(0,st.length(),"");
            buffer.append(st);
        }
    }
}


Related Tutorials/Questions & Answers:
how to print the following pattern
how to print the following pattern  Hello hEllo heLlo helLo hellO pls reply soon its an emergency   class StringPattern { public static void main(String[] args) { String st="hello
How to print the following pattern in java?
How to print the following pattern in java?  How to print the following pattern in java? he he is he is going he is going in   import java.io.*; class StringPattern { public static void main(String[] args
Advertisements
How to print the following output using c program
How to print the following output using c program  1) 4 3 4 2 3 4 1 2 3 4 2) A B C D E F G H I J
Print the following format
Print the following format  how to print the following format given string "00401121" in java 0-** 1-* 2-* 3- 4
print the below pattern
print the below pattern  to write a program using a function ti initialize a character 'A' and print the following pattern of characters upto six lines A A B A B C A B C D A B C D E A B C D E F
print rectangle pattern in java
print rectangle pattern in java  * * * * * * * how to generate this pattern in java??   Hi friend try this code may this will helpful for you public class PrintRectangle { public static void main
print array in following format
print array in following format  i want print two array in following format first array= 1,2,3,4,5,6,7,8,9 second array=11,12,13,14,15,16,17,18,19 i...; Here is a code that displays the array values in the following pattern: 1 2
C program to print the following
C program to print the following  Hello, Some one help me with a "C Program" to print the following as output: 4444444 4333334 4322234 4321234 4322234 4333334 4444444 // for input 4. And also
print the following series
print the following series  a b c d e b c d e c d e d e e   Hi Friend, Try the following code: class StringPattern { public static void main(String[] args) { String st="abcde
how to make this pattern???
how to make this pattern???  how to make following pattern in javascript
write a program in C to print following triangles on the screen
write a program in C to print following triangles on the screen  write a program in C to print following triangles on the screen
C Program to Print Following Output - Development process
C Program to Print Following Output  Hello Sir I wnat to print Followning output in C Language with for loop How I Can Print it? 5 5 4 5 4 3 5 4 3 2 5 4 3 2 1  Hi Friend, Try the following: #include
How to print this in java?
How to print pattern in Java?  How to print a particular pattern...;  How to print this in java...;The pattern
i want print the following out put
i want print the following out put  Hello sir i want the following out put can u provide the program in c# o/p; HELLOLLEH HELLLEH HELEH HEH H
how to get following output
how to get following output  input 123456 output 1 2 3 4 5 6
how to get following output
how to get following output  input 123456 output 1 2 3 4 5 6
how to print the server time
how to print the server time  how to print the server time in jsp and update time in fix interval
How to print this Format exactly?
How to print this Format exactly?   * * * & reverse
Pattern
Pattern  How to print this pattern in Java please help me A AC ACE ACEG ACEGI The program should be right to left
how to print the server time
how to print the server time  i want to print database time in clintside and update time in every secound without creating connection to database for each time. how can i do
how to print - Java Beginners
how to print  how to print something on console without using System.out.print() method ?  Hi Friend, You can use PrintWriter to write anything on the console. import java.io.*; public class Print{ public static
pattern
be between 2 and 9. The following shows the four pattern in size 5. Pattern 1 5... and a pattern size only between 2 and 9. You are print the menu and the user's response... of different sizes. The size of each pattern is determined by the number
How to change the cloth pattern, change the cloth pattern, cloth pattern
How to change the cloth pattern       We are going to change the cloth pattern by using a simple way... Pattern. Now change layer settings. You will get this picture.   Layer
how to print pdf format
how to print pdf format  Hi every body iam doing school project iam using backend as oracle front end java .how to print student marks list /attendence in pdf format. please help me. thanks in advance.   Here
How to design a foot print on the sand, print on the sand, print
How to design a foot print on the sand       You might have seen foot prints on the sand field. Do you think, it can be design in the photoshop, yes I have done here. I have used
how to print JInternal frame component ?
how to print JInternal frame component ?  hello sir, i devalop a swing application .but problem is that how display report & print it. some data prefech from database & keep to jtable but how it is print with table
how to make following pyramid using loop
how to make following pyramid using loop   1 212 32123 4321234... that displays the following pattern: 1 212 32123 4321234 543212345 4321234 32123 212 1 class Pattern{ public static void main(String
How can print integer in method
How can print integer in method   a method call process public process(int jobid,int remain){ } how to print int jobid ,int remain in for loop jobid in proc[0],remain in proc[1],both show in text file how to print proc[0
print
print  How to print JFrame All Componant?   Please visit the following link: http://www.roseindia.net/java/example/java/swing/Print.shtml
how to print headings horizontally in jsp
how to print headings horizontally in jsp  In one of my jsp i have used for loop. in every iteration it will fetch value from db and print it on heading section, it prints vertically but my requirement is to print it horizontally
how to retrieve the url pattern of the requesting servlet?
how to retrieve the url pattern of the requesting servlet?  Hi... servlet1, you are going to servlet2. So in the servlet2 how you will display the url pattern of the servlet1? This is my question. please answer me soon
Pattern Making
Pattern Making  how to print this pattern in java? * * * * * * * * * * * * * * * * * It is just an example
how to get following answer in turbo c program
how to get following answer in turbo c program  input 123456789 output 1 2 3 4 5 6 7 8 9
pattern
pattern  1 3 1 5 3 1 7 5 3 1 9 7 5 3   Here is a number pattern example. 1 3 1 5 3 1 7 5 3 1 9 7 5 3 1 class Pattern{ public static void main(String args[]){ for(int i=1;i<=9;i
How to pretty print XML from Java?
How to pretty print XML from Java?  How to pretty print XML from Java
How to print a webpage without url and date in jsp ?
How to print a webpage without url and date in jsp ?  How to print a webpage without url and date in jsp
how to print all colors using awt
how to print all colors using awt  how to print all colors using awt
how to print of hours and minutes of 8725 seconds
how to print of hours and minutes of 8725 seconds  how to print of hours and minutes of 8725 seconds
How to access the following tag from xml to jsp
How to access the following tag from xml to jsp  How can i get the title where cat="1" and "My Title" from XML File?   Please visit the following link: http://www.roseindia.net/jsp/parsing-xml.shtml The above link
Pattern
Pattern  1234321 123 321 12 21 1 1 please,give me this pattern in java   class Sixth_1 { public static void main(String args...; } } }   Here is a number pattern class Pattern{ public
How to Print a Stack Trace Message
How to Print a Stack Trace Message  Debugging of Java program requires... times you have to print the detailed error message on the console... will print the detailed message on the console. You can use
how to print from right to left in java????
how to print from right to left in java????   can anyone pls tell how to print from right to left in java
how to create an xml file in following clear format
how to create an xml file in following clear format  anyone please help me out to create this file,,. <Tasks> <Taskid>1 <Taskname>Coding <Project>CeMIC <Date>
how to call the print dialog box through JMenuItem
how to call the print dialog box through JMenuItem  What is the way to call the print dialog box through JMenuItem to print the current page...could you please help me by sending code
How to call print dialog box through JMenuItem?
How to call print dialog box through JMenuItem?  What is the way to call the print dialog box through JMenuItem to print the current page like we can do in javascript by calling window.print() function
How to get filename in JTextArea in following case?
How to get filename in JTextArea in following case?  Hi, i'm trying to code a GUI in java, the following code is working but the filenam is not displayed in the JTextArea, why? [CODE] private void
How to print contents of a web page in jsp?
How to print contents of a web page in jsp?  I have generated a pay slip using jsp.How do I print the contents of the slip
how to add a update button in the following jsp
how to add a update button in the following jsp  Once the excel from the following jsp is loaded to the broswer, how to add a button in the jsp to allow the user to update the excel? thanks, <%@page import="java.io.*"%>
error occured in following page ... how to resolve it?
error occured in following page ... how to resolve it?  // to convert image into thumbnail i used following code. But netbeans has given me following error ....wht i shud do???????? i m java beginner so plz explain in smooth way
How to Print Array in JavaScript
How to Print Array in JavaScript In this section you will learn about Array...=mycity.indexOf["Agra"]//return the index of Agra Now, here is the example how...;<h2>Click to print the array element</h2></p><p><input
Advertisements
 

 

 

DMCA.com