Skip to main content
added 1 character in body
Source Link
ChrisG
  • 7.4k
  • 2
  • 17
  • 26

soSo complete rookie i saw functions from other peoples code n stuff

#include <stdio.h>
#include <cs50.h>
int main(void)
{
int h,i,s,k;
//get user input and follow limitations
do{ 
    printf ("height: ");
h = GetInt();
}while ((h<0)||(h>23));



 //start one counter to end printing after achieving height
//second conter (s) for spaces on individual lines
//third counter (k) for hashes/sharps 
//then print new line

for(i=0,i<=h,i++);
{
for(s=0,s<(h-i-1),s++);
{
printf(" ");
  }
for(k=0,k<(i+2),k++);
{
printf("#");
}
printf("\n");
}
return(0);
} 
   
#include <stdio.h>
#include <cs50.h>
int main(void)
{
    int h, i, s, k;
    //get user input and follow limitations
    do {
        printf("height: ");
        h = GetInt();
    } while ((h < 0) || (h > 23));

    //start one counter to end printing after achieving height
    //second conter (s) for spaces on individual lines
    //third counter (k) for hashes/sharps
    //then print new line

    for (i = 0, i <= h, i++);
    {
        for (s = 0, s < (h - i - 1), s++);
        {
            printf(" ");
        }
        for (k = 0, k < (i + 2), k++);
        {
            printf("#");
        }
        printf("\n");
    }
    return(0);
}
   

and then an overwhelming response of 12 errors mainly for for condition and it's semi colon and loop breaker condition and pretty sure more to come please help this is getting scary

so complete rookie i saw functions from other peoples code n stuff

#include <stdio.h>
#include <cs50.h>
int main(void)
{
int h,i,s,k;
//get user input and follow limitations
do{ 
    printf ("height: ");
h = GetInt();
}while ((h<0)||(h>23));



 //start one counter to end printing after achieving height
//second conter (s) for spaces on individual lines
//third counter (k) for hashes/sharps 
//then print new line

for(i=0,i<=h,i++);
{
for(s=0,s<(h-i-1),s++);
{
printf(" ");
  }
for(k=0,k<(i+2),k++);
{
printf("#");
}
printf("\n");
}
return(0);
} 
   

and then an overwhelming response of 12 errors mainly for for condition and it's semi colon and loop breaker condition and pretty sure more to come please help this is getting scary

So complete rookie i saw functions from other peoples code n stuff

#include <stdio.h>
#include <cs50.h>
int main(void)
{
    int h, i, s, k;
    //get user input and follow limitations
    do {
        printf("height: ");
        h = GetInt();
    } while ((h < 0) || (h > 23));

    //start one counter to end printing after achieving height
    //second conter (s) for spaces on individual lines
    //third counter (k) for hashes/sharps
    //then print new line

    for (i = 0, i <= h, i++);
    {
        for (s = 0, s < (h - i - 1), s++);
        {
            printf(" ");
        }
        for (k = 0, k < (i + 2), k++);
        {
            printf("#");
        }
        printf("\n");
    }
    return(0);
}
   

and then an overwhelming response of 12 errors mainly for for condition and it's semi colon and loop breaker condition and pretty sure more to come please help this is getting scary

Rollback to Revision 1
Source Link
ChrisG
  • 7.4k
  • 2
  • 17
  • 26

solved... and closed 12 errors for pset1 mario

i did it nevermind

so complete rookie i saw functions from other peoples code n stuff

#include <stdio.h>
#include <cs50.h>
int main(void)
{
int h,i,s,k;
//get user input and follow limitations
do{ 
    printf ("height: ");
h = GetInt();
}while ((h<0)||(h>23));



 //start one counter to end printing after achieving height
//second conter (s) for spaces on individual lines
//third counter (k) for hashes/sharps 
//then print new line

for(i=0,i<=h,i++);
{
for(s=0,s<(h-i-1),s++);
{
printf(" ");
  }
for(k=0,k<(i+2),k++);
{
printf("#");
}
printf("\n");
}
return(0);
} 
   

and then an overwhelming response of 12 errors mainly for for condition and it's semi colon and loop breaker condition and pretty sure more to come please help this is getting scary

solved... and closed

i did it nevermind

#include <stdio.h>
#include <cs50.h>
int main(void)
{
int h,i,s,k;
//get user input and follow limitations
do{ 
    printf ("height: ");
h = GetInt();
}while ((h<0)||(h>23));



 //start one counter to end printing after achieving height
//second conter (s) for spaces on individual lines
//third counter (k) for hashes/sharps 
//then print new line

for(i=0,i<=h,i++);
{
for(s=0,s<(h-i-1),s++);
{
printf(" ");
  }
for(k=0,k<(i+2),k++);
{
printf("#");
}
printf("\n");
}
return(0);
} 
   

and then an overwhelming response of 12 errors mainly for for condition and it's semi colon and loop breaker condition and pretty sure more to come please help this is getting scary

12 errors for pset1 mario

so complete rookie i saw functions from other peoples code n stuff

#include <stdio.h>
#include <cs50.h>
int main(void)
{
int h,i,s,k;
//get user input and follow limitations
do{ 
    printf ("height: ");
h = GetInt();
}while ((h<0)||(h>23));



 //start one counter to end printing after achieving height
//second conter (s) for spaces on individual lines
//third counter (k) for hashes/sharps 
//then print new line

for(i=0,i<=h,i++);
{
for(s=0,s<(h-i-1),s++);
{
printf(" ");
  }
for(k=0,k<(i+2),k++);
{
printf("#");
}
printf("\n");
}
return(0);
} 
   

and then an overwhelming response of 12 errors mainly for for condition and it's semi colon and loop breaker condition and pretty sure more to come please help this is getting scary

deleted 44 characters in body; edited title
Source Link

12 errors for pset1 mario solved... and closed

so complete rookie i saw functions from other peoples code n stuff

i did it nevermind

#include <stdio.h>
#include <cs50.h>
int main(void)
{
int h,i,s,k;
//get user input and follow limitations
do{ 
    printf ("height: ");
h = GetInt();
}while ((h<0)||(h>23));



 //start one counter to end printing after achieving height
//second conter (s) for spaces on individual lines
//third counter (k) for hashes/sharps 
//then print new line

for(i=0,i<=h,i++);
{
for(s=0,s<(h-i-1),s++);
{
printf(" ");
  }
for(k=0,k<(i+2),k++);
{
printf("#");
}
printf("\n");
}
return(0);
} 
   

and then an overwhelming response of 12 errors mainly for for condition and it's semi colon and loop breaker condition and pretty sure more to come please help this is getting scary

12 errors for pset1 mario

so complete rookie i saw functions from other peoples code n stuff

#include <stdio.h>
#include <cs50.h>
int main(void)
{
int h,i,s,k;
//get user input and follow limitations
do{ 
    printf ("height: ");
h = GetInt();
}while ((h<0)||(h>23));



 //start one counter to end printing after achieving height
//second conter (s) for spaces on individual lines
//third counter (k) for hashes/sharps 
//then print new line

for(i=0,i<=h,i++);
{
for(s=0,s<(h-i-1),s++);
{
printf(" ");
  }
for(k=0,k<(i+2),k++);
{
printf("#");
}
printf("\n");
}
return(0);
} 
   

and then an overwhelming response of 12 errors mainly for for condition and it's semi colon and loop breaker condition and pretty sure more to come please help this is getting scary

solved... and closed

i did it nevermind

#include <stdio.h>
#include <cs50.h>
int main(void)
{
int h,i,s,k;
//get user input and follow limitations
do{ 
    printf ("height: ");
h = GetInt();
}while ((h<0)||(h>23));



 //start one counter to end printing after achieving height
//second conter (s) for spaces on individual lines
//third counter (k) for hashes/sharps 
//then print new line

for(i=0,i<=h,i++);
{
for(s=0,s<(h-i-1),s++);
{
printf(" ");
  }
for(k=0,k<(i+2),k++);
{
printf("#");
}
printf("\n");
}
return(0);
} 
   

and then an overwhelming response of 12 errors mainly for for condition and it's semi colon and loop breaker condition and pretty sure more to come please help this is getting scary

Source Link
Loading