Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // ConsoleApplication1.cpp : 定義主控台應用程式的進入點。
- //
- #include "stdafx.h"
- #include <iostream>
- #include <string>
- using namespace std;
- int main()
- {
- while (1) {
- string a = { "" }, b = { "" };
- int n[2] = { 0 };
- cout << "輸入二個字串";
- cin >> a >> b;
- n[0] = size(a);
- n[1] = size(b);
- if (n[0] == n[1])
- cout << "YES" <<endl;
- if (n[0] != n[1])
- cout << "NO" <<endl;
- system("PAUSE");
- system("CLS");
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement