04 2023 档案
摘要:一.问题描述:找出1-100之间的质数。 二.问题分析:质数是只能将自己和1整除,所以通过循环语句和判断语句判断这个数是否只能整除自己和1; 三.流程图演示: 在文件里查看 四.代码实现: #include<iostream> using namespace std; int main() { co
阅读全文
摘要:例7-1: #include<iostream> #include<cmath> using namespace std; class point { public: void initpoint(float x = 0, float y = 0) { this->x = x; this->y =
阅读全文