..`quiz_question (doubt_2)

"/* Output ? */
#include
using namespace std;

int main(){
long signed CodingBlocks = 2017;
short unsigned BOSS1 = -2018;
unsigned BOSS2 = -2019;
int BOSS3 = -2020;
long long unsigned BOSS4 = -2021;
short unsigned Nagarro = 2018.9;
long signed HackerBlocks = ‘A’;
cout<<CodingBlocks<<endl;
cout<<BOSS1<<endl<<BOSS2<<endl<<BOSS3<<endl<<BOSS4<<endl;
cout<<Nagarro<<endl;
cout<<HackerBlocks<<endl;

return 0;
}"

hey @3lokesharora, It will gave you error because wrong modifier are used with particular datatype. Check below link to learn, it is very helpful for doing such types of questions.
https://codescracker.com/cpp/cpp-modifier-types.htm

!

on devc++ output is this

quiz on coding blocks shows this output

hey @3lokesharora, on coding blocks it is giving ASCII value of ‘A’ because it is considering at as integer type. You may get different outputs depending upon version of compiler. DevC++ is not considering as integer thatswhy it is reporting error.

hey @3lokesharora if no further query,please mark this doubt as resolved.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.