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

📄 multiples.cpp

📁 C++上机课的习题答案
💻 CPP
字号:
// multiples.cpp
//判断第一个整数是否为第二个整数的的倍数。
//提示:用求余符号% 
#include <iostream>

using std::cout;
using std::cin;
using std::endl;

int main()
{
   /* Write variable declarations(变量声明) here */

   cout << "Enter two integers: ";
   /* Write a cin statement to read data into variables here */

   if ( /* Write a condition that tests if number1 is a multiple of 
           number2 */ )
      cout << number1 << " is a multiple of " << number2 << endl;

   if ( /* Write a condition that tests if num1 is not a multiple 
           of num2 */ )
      cout << number1 << " is not a multiple of " << number2 << endl;

   system("PAUSE");
   return 0;

} // end main


⌨️ 快捷键说明

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