CodePudding user response:
Don't debugging
Int a [15] {}, j=0; While (j<15) a [j]=j * 2, + + j. j=0; While (j<15) cout<(a [j] <10?" ":" ") & lt;
CodePudding user response:
Don't debugging
Char aa [47] {}; Cin> Aa; Int j=0; While (aa/j++!='\ 0'); - j;
Int jj=0; While (jj<- j) if (aa/jj++!=aa cout< [j]); <" No, j="jj; Else if (j<=cout< jj); <" Yes ";
CodePudding user response:
# include
using namespace std;
Const int LENGTH=15;
Int main ()
{
Int arr (LENGTH),//define array
//array element coupling numerical
for (int i=0; I & lt; LENGTH; + + I)
{
Arr [I]=I * 2;
}
for (int i=0; I & lt; LENGTH; + + I)
{
coutIf ((I + 1) % 5==0)//if already output 5, the line feed
{
cout}
}
return 0;
}
VS2015 debugging c + +
CodePudding user response:
# include
using namespace std;
Bool IsPalinDrome (char * ch, int len);//judge whether palindrome function
Int main ()
{
If (IsPalinDrome (abcdcba, strlen (" abcdcba ")))
{
cout <"Abcdcba is a palindrome";
}
The else
{
cout <"Isn't abcdcba palindrome";
}
return 0;
}
Bool IsPalinDrome (char * ch, int len)//ch is to determine the string, len is the length of the string
{
for (int i=0; I & lt; Len. + + I)
{
If (ch [I]!=ch [len - 1 - I])
{
return false;//is not a palindrome, returns false
}
}
return true;//is a palindrome, return true
}
VS2015 debugging c + +
CodePudding user response: