"I LOVE MY COUNTRY"
write a c program to get "COUNTRY MY LOVE I" as the output.
Use any other programming language. It is not mandatory to
use C.
Answer Posted / debmalya paul
package Stringmltp;
import java.util.Scanner;
public class country {
static Scanner in=new Scanner(System.in);
void rev()
{
String s=in.nextLine();
System.out.print(s.substring(10,17) +" "+ s.substring(7,9) +" "+ s.substring(2,6) +" "+ s.substring(0,1));
}
public static void main(String []args)
{
country cn=new country();
cn.rev();
}
}
Is This Answer Correct ? | 2 Yes | 3 No |
Post New Answer View All Answers
Can one function call another?
What is extern c used for?
What is equivalent to ++i+++j?
Where are some collections of useful code fragments and examples?
What is the purpose of main( ) in c language?
Why doesnt long int work?
How do you list a file’s date and time?
any "C" function by default returns an a) int value b) float value c) char value d) a & b
i have to apply for the rbi for the post of officers. i need to know abt the entrance questions whether it may be aps or techinical....
How does sizeof know array size?
Why #include is used in c language?
What is the package for freshers(Non IIT) in amazon(hyderabad). And what is the same for those who are a contract employee.
What are qualifiers in c?
Which type of language is c?
write a c program to calculate sum of digits till it reduces to a single digit using recursion