C++ Input Output

C++的IO比较复杂,记录一下碰到的问题:

#include "stdafx.h"
#include <iostream>

using namespace std;

int main(int argc, char* argv[])
{
    cout << 22/5*3 << endl;
    printf("Hello World!
");
    return 0;
}

居然输出整数12,而不是浮点数

原文地址:https://www.cnblogs.com/findumars/p/3746753.html