※ 引述《nfsong (我要當總圖的怪老頭)》之銘言:
: #include <stdio.h>
: #include <iostream.h>
: int main ()
: { // insert code here...
: while(1)
: {
: int result,a;
: a=1;
: result=(a++*5)+(a++*3);
: break;}
: cout<<result<<endl; return 0;}
: 這樣寫他不給編譯ㄝ
: 是vc++不能允許這種語法 ??
很簡單 因為你標頭檔給錯了
c++的cout 對應的標頭檔是
#include<iostream> //你多一個.h
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 140.116.141.195