how to print the following pattern

how to print the following pattern

Hello hEllo heLlo helLo hellO

pls reply soon its an emergency

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 String as pattern ?
how to print String as pattern ?  i have a one String name ="rajesh" i want to print pattern like r * ra ** raj raje rajes rajesh please help me
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:ADS_TO_REPLACE_1 class StringPattern { public static void main(String[] args) { String st="abcde
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
how to make this pattern???
how to make this pattern???  how to make following pattern in javascript
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 (adsbygoogle = window.adsbygoogle || []).push
Pattern
Pattern  How to print this pattern in Java please help me A AC ACE ACEG ACEGI The program should be right to left
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 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
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... Halftone Pattern. ADS_TO_REPLACE_2 Now change layer settings. You will get
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 UIButton id
How to print UIButton id  How to get the id of the button in the IOS application? Thanks   Hi, You can use the following code: - (IBAction)btnClicked:(id)sender { UIButton *button = (UIButton *)sender; int
Pattern Making
Pattern Making  how to print this pattern in java? * * * * * * * * * * * * * * * * * It is just an example
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
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 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 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 to print current time in r?
How to print current time in r?  Hi, I am learning and want to print current date and time on console. How to print current time in R Programming... and time. Following is the example usage of above function to get current date
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 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 print spark dataframe data
how to print spark dataframe data  Hi, I have a dataframe in spark and i want to print all the data on console. How it can be done. how to print... is in "data" variable and you want to print it. Its simple and one line function to print
how to print spark dataframe data
how to print spark dataframe data  Hi, I have a dataframe in spark and i want to print all the data on console. How it can be done. how to print... is in "data" variable and you want to print it. Its simple and one line function to print
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 print like printf in python
How to print like printf in python  Hi, I am from C background and there used to be printf function. Jow to print like printf in python? The printf function is C/C++ is very useful. So, looking for some line printf in Python
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
how to print dot in python without newline
how to print dot in python without newline  Hi, I a debugging python program and I am using following code to print dots: print... to print 20 dots without new line. Is there any easy solution? how to print dot
how to print dot in python without newline
how to print dot in python without newline  Hi, I a debugging python program and I am using following code to print dots: print...? how to print dot in python without newline?ADS_TO_REPLACE_2 Can I use variable
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 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
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 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 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 pretty print XML from Java?
How to pretty print XML from Java?  How to pretty print XML from Java
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 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 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 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

Ads