#include <windows.h>
#include <process.h>
#include <stdio.h>
#include <vector>
#include <string>
#include <iostream>
using namespace std;

 

int WINAPI WinMain( HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow){

if (!::AttachConsole(ATTACH_PARENT_PROCESS))   ::AllocConsole();           // コマンドプロンプトからの起動じゃない時は新たに開く

freopen("CON", "r", stdin);     // 標準入力の割り当て
freopen("CON", "w", stdout);    // 標準出力の割り当て

printf("input no ... \n");
int num;
scanf("%d", &num);
std::cout << num << std::endl;


//::FreeConsole();                // 割り当て解除


}