Ask a Question | Answer a Question! |
![](/img/l.gif)
Submitting your question...
ResFinder - Thousands of Practice Papers
I'm so glad. You guys suffer while we literally have NO theory whatsoever. #BlessedLife |
![](//pl.respaper.com/64/maihuarya.jpg) |
asked by Arya Shahir (maihuarya) 6 years ago |
3 |
Convert snippet using ternary operator:
if (n>m)
{
s=n/m;
m++;}
else
{ s=m/n;
n++;
} |
![](//pl.respaper.com/64/hermione02.jpg) |
asked by Shreya Bhagat (hermione02) 6 years ago |
2 |
anyone here with cookery?? |
![](//pl.respaper.com/64/somay2003.jpg) |
asked by Somay Vaidh (somay2003) 6 years ago |
2 |
Is it compulsory to comment in a program? as said by @NehalG |
![](//pl.respaper.com/64/arya9591.jpg) |
asked by Atharva45 (arya9591) 6 years ago |
3 |
during photosynthesis the oxygen in glucose comes from?? water or co2 |
![](//pl.respaper.com/64/arcade_7.jpg) |
asked by Amu Arcade (arcade_7) 6 years ago |
2 |
// programme to find whether a string is palindrome or not?
import java.util.*;
import java.io.*;
public class StringPalindrome
{
public void check()
{Scanner sc=new Scanner(System.in);
String s1;
System.out.println(" enter a string");
s1=sc.nextLine();
StringBuffer a1=new StringBuffer(s1);
StringBuffer a2=new StringBuffer((a1.reverse()));
if(a1.equalsIgnoreCase(a2))
{
System.out.println(" the string is a palindrome ");
}
else
{
System.out.println(" the string is not a palindrome");
}
}
public static void main()
{
StringPalindrome a=new StringPalindrome();
a.check();
}
}
i am getting this error:
/StringPallindrome.java:16: error: cannot find symbol
if(a1.equalsIgnoreCase(a2))
^
symbol: method equalsIgnoreCase(StringBuffer)
location: variable a1 of type StringBuffer
1 error
please tell what changes should i do in this programme? |
![](//pl.respaper.com/64/sameed.jpg) |
asked by Sameed Hussain (sameed) 6 years ago |
4 |
Give an example of data abstraction |
![](//pl.respaper.com/64/nehalg.jpg) |
asked by Nehal G (nehalg) 6 years ago |
3 |
System.out.println((int)(Math.random()*10)); what are the range of possible out comes |
![](//pl.respaper.com/64/mdarfath.jpg) |
asked by Rtstud (mdarfath) 6 years ago |
2 |
Today is World Water Day....Save Water Save Earth. |
![](//pl.respaper.com/64/devanshu8.jpg) |
asked by ⚡The Flash⚡ (devanshu8) 6 years ago |
1 |
What happens when we declare the access modifier of a class as final?
public final void main(){
.... |
![](//pl.respaper.com/64/siddhant94.jpg) |
asked by Siddhant Joshi (siddhant94) 6 years ago |
2 |