Answer:
That is called declaring a variable
Explanation:
Answer:
#include <bits/stdc++.h>
using namespace std;
bool isPalindrome(string str)
{
char a,b;
int length = str.length();
for (int i = 0; i < length / 2; i++)
{
a=tolower(str[i]);//Converting both first characters to lowercase..
b=tolower(str[length-1-i]);
if (b != a )
return false;
}
return true;
}
int main() {
string t1;
cin>>t1;
if(isPalindrome(t1))
cout<<"The string is Palindrome"<<endl;
else
cout<<"The string is not Palindrome"<<endl;
return 0;
}
Output:-
Enter the string
madam
The string is Palindrome
Enter the string
abba
The string is Palindrome
Enter the string
22
The string is Palindrome
Enter the string
67876
The string is Palindrome
Enter the string
444244
The string is not Palindrome
Explanation:
To ignore the cases of uppercase and lower case i have converted every character to lowercase then checking each character.You can convert to uppercase also that will also work.
Answer:
A) ALU
Explanation:
The arithmetic logic unit (ALU) performs the arithmetic and logical functions that are the work of the computer.
So, the correct option is - A) ALU
Correct Question:
Public class N extends String, Integer { } When you compile, you get the following message: N.java:1: ‘{‘ expected public class N extends String, Integer ^ 1 error Explain what the problem is and how to fix it.
Note the capital letter P
Answer and Explanation:
Problem: This is a syntax error, the key word "public" should begin with a small letter and not capital letter.
How to fix: Replace the capital letter P by small letter p and recompile.
Answer:
get out there outside and get out and see what you do when you're ready for a workout or a day off and you're going through the