⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 重载5.13.cpp

📁 本程序用C++实现华氏与摄氏温度的转换.函数运算.与系统时间显示
💻 CPP
字号:
#include <iostream.h>
#include <iomanip.h>
int square(int,int);
float square(float,float);
int main()
{ int a,b;
  float c,d;
  cout<<"输入整数"<<endl;
  cin>>a>>b;
  cout<<"输入浮点数"<<endl;
  cin>>c>>d;
  cout<<"The square of integer"<<a<<setw(3)<<b<<"is"<<square(a,b)<<endl;
  cout<<"The square of float"<<c<<setw(5)<<d<<"is"<<square(c,d)<<endl;
  return(0);
}
int square(int a,int b)
{  return (a*a+b*b); }
float square(float c,float d)
{  return (c*c+d*d); }

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -