Write a corrected statement in c++ so that the statement
will work properly. if (x = y) x = 2*z;

Answers were Sorted based on User's Feedback



Write a corrected statement in c++ so that the statement will work properly. if (x = y) x = 2*z;..

Answer / rose

if(x==y)
{
x=2*z;
}

Is This Answer Correct ?    1 Yes 1 No

Write a corrected statement in c++ so that the statement will work properly. if (x = y) x = 2*z;..

Answer / kannan

if(x==y)
printf("x=2*z");

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C++ General Interview Questions

How is c++ used in the real world?

1 Answers  


What is jump statement in C++?

1 Answers   Ericsson,


What are arrays c++?

1 Answers  


What's the most powerful programming language?

1 Answers  


What is the main purpose of c++?

1 Answers  


What are different types of polymorphism supported by C++

2 Answers   CA, GameLoft,


What is the advantage of an external iterator.

1 Answers  


i want to know how to copy arrary without using any method or function. I have tried the below using System; class e4 { static void Main(string[] args) { int a,b; int[ ] m= new int[5]; int[ ] n= new int[5]; for(a=0;a<=4;a++) { Console.WriteLine("enter any value"); m[a]=Convert.ToInt32(Console.ReadLine()); m[a]=n[a]; } for(b=0;b<=4;b++) { Console.WriteLine(n[b]); } } } but it will give wrong result can anyone solve this problem

1 Answers   Reliance,


Which sort is best for the set: 1 2 3 5 4 a) Quick Sort b) Bubble Sort c) Merge Sort

1 Answers  


What is the use of ‘using’ declaration?

1 Answers  


What are member functions used in c++?

1 Answers  


What is a lambda function c++?

1 Answers  


Categories