class yam
{
public static void findIndex()
{
String s="allendowlley";
int index=0;
int l=s.length();
while(index<l)
{
index=s.indexOf('l',index);
Type: Posts; User: moodycrab3
class yam
{
public static void findIndex()
{
String s="allendowlley";
int index=0;
int l=s.length();
while(index<l)
{
index=s.indexOf('l',index);
OH MY GOD... u are a genius... Thank you so much... I have been trying to figure this out since yesterday... Thank you so very much....
thank you
thank you
class jack
{
public static String reverseString(String s, String result,int l)
{
if(l>=0)
{ result=result+s.charAt(l);
reverseString(s,result,l-1);
return result;}
else
return "error";
sorry... My bad... I understand now... Thanks everybody...
I understand what you mean.... Thanks so very much...!!!
class div
{
public static boolean div(int x, int y)
{
boolean pig;
pig=x%y==0;
if(pig)
return pig;
else
return !pig;
You mean for every If statement there has to be an else statement.... or else the logic doesn't work...
Even if I add
If(n<0)
return 0;
meaning even when all the possible conditions are addressed...... the output is still "return statement missing"
I think the problem lies with the recursive...
class keg
{
public static int fact(int n)
{
int factorial;
if(n>0)
{
factorial=n*fact(n-1);
return factorial;
}