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

📄 prog4_01.cpp

📁 c++最经典的入门书籍
💻 CPP
字号:
// Program 4.1 Comparing data values
#include <iostream>
using std::cin;
using std::cout;
using std::endl;

int main() {
  char first = 0;                       // Stores the first character
  char second = 0;                      // Stores the second character

  // Prompt for and read in the first character
  cout << "Enter a character: ";
  cin >> first;

  // Prompt for and read in the second character
  cout << "Enter a second character: ";
  cin >> second;

  cout << "The value of the expression first < second is: "
       << (first < second)
       << endl
       << "The value of the expression first == second is: "
       << (first == second)
       << endl;

  return 0;
}

⌨️ 快捷键说明

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