C++ 第一个程序 C++ Primer PlusC

选择的结果怎样,现在还看不到,但时间会揭开一切

这算是用C++ 敲的第一个程序,从此开始高级语言之路

#include <iostream>
using namespace std;//放在外面对应全局。放在当前函数下仅限于当前函数使用
 void time(int h,int m);
int main()

 int hour,minutes;
 cout << "Enter the number of hours: " << endl;
 cin >>hour;
 cout << "Enter the number of minutes: " << endl;
 cin >> minutes;
 time(hour,minutes);
}
void time(int h,int m)
{
 
 cout <<"Time: "<<h<<":"<<m<<endl;
 cin.get();
 cin.get();
}

原文链接: https://www.cnblogs.com/fdtick/p/3161871.html

欢迎关注

微信关注下方公众号,第一时间获取干货硬货;公众号内回复【pdf】免费获取数百本计算机经典书籍

    C++ 第一个程序 C++ Primer PlusC

原创文章受到原创版权保护。转载请注明出处:https://www.ccppcoding.com/archives/93801

非原创文章文中已经注明原地址,如有侵权,联系删除

关注公众号【高性能架构探索】,第一时间获取最新文章

转载文章受原作者版权保护。转载请注明原作者出处!

(0)
上一篇 2023年2月10日 上午2:19
下一篇 2023年2月10日 上午2:20

相关推荐