when i use cout or cin call & then either << or >> .....it shows
declaration syntax error...what should i do?
cout<<"anything";
int a;
cin>>a;
return 0;
Answers were Sorted based on User's Feedback
Answer / nilam
If you are using Turbo C complier need to add #include<iostream.h> header file.
and If you are using Visual Studio then you need to add
#include<iostream>
using std namespace;
the above two statements.
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / ramchandranaik
if you are using Turbo C complier need to add #include<iostream.h>
header file.
or if ur using dev C++ then
#include<iostream>
using namespace std;
| Is This Answer Correct ? | 0 Yes | 0 No |
I'm having trouble with coming up with the correct code. Thank You!! The assignment was to write a program using string functions that accepts a price of an item and displays its coded value. The base of the keys: X C O M P U T E R S 0 1 2 3 4 5 6 7 8 9 Sample I/O Dialogue: Enter Price: 489.50 Coded Value: PRS.UX
UINT i,j; i = j = 0; i = ( i++ > ++j ) ? i++ : i--; explain pls....
#include<stdio.h> void main() { int i=1; printf("%d%d%d",i++,++i,i); }
How to reverse a linked list without using array & -1? Thank you.
How to upgrade LOOP environment, I just mean, how can i make loop statement editable ? I just try some program using loop statement and checking it in multiple compilers. Every compiler showing different output, what's the wrong ? is it a compiler based problem, or loop based problem, tell me why ? and what will be the debugging process, for this kind of problem ?
Display this kind of output on screen. 1 0 1 1 0 1 3. Display this kind of output on screen. 1 1 0 1 0 1 4. Display this kind of output on screen. 1 1 0 1 0 1 5.Display this kind of output on screen. 1 2 3 4 5 6 7 8 9 10
Using string functions write a program that will accept the name of the capital as input value and will display the corresponding country. ------------------------ Capitals Countries ------------------------ Capitals Countries Ottawa Canada Moscow Russia Rome Italy I can't not get it to run properly
Given that two int variables, total and amount , have been declared, write a sequence of statements that: initializes total to 0 reads three values into amount , one at a time. After each value is read in to amount , it is added to the value in total (that is, total is incremented by the value in amount ). Instructor's notes: If you use a loop, it must be a for loop. And if you use a loop control variable for counting, you must declare it.
void main() { int i=1; printf("%d%d%d",i,++i,i++); } Cau u say the output....?
what is meant for variable not found?
void main() { int i=5,y=3,z=2,ans; clrscr(); printf("%d",++i + --z + i++ + --i * ++y); i=5,y=3,z=2; ans=++i + --z + i++ + --i * ++y; printf("\n%d",ans); getch(); } Its output is 37 and 31.... Please explain me why its different How it works.....
Write a C program to enter 10 integer numbers through one variable and count how many of them are even using while loop ?