摘要: #include<stdio.h>typedef struct{ int year; int month; int day;}DATE;int countday(DATE today);int runyear(int year);int main(){ DATE today; int totalda 阅读全文
posted @ 2023-04-18 12:37 jmhyyds 阅读(45) 评论(0) 推荐(0)
摘要: using namespace std; class Base {public: virtual void tall();}; class People : Base {public: void tall() { cout << "people" << endl; };}; 在 main 方法中,我 阅读全文
posted @ 2023-04-17 21:36 jmhyyds 阅读(9) 评论(0) 推荐(0)
摘要: #include <iostream>using namespace std;int f(int a[]){ int i,f=0; for(i=0;i<=9;i++){ if(a[0]!=a[i]) f=1; }return f; }int main(){ int a[10]={10,2,8,22, 阅读全文
posted @ 2023-04-16 20:37 jmhyyds 阅读(31) 评论(0) 推荐(0)
摘要: 源码: #include<iostream>using namespace std;int main(){ int a,b,c,count=0; for(a=1;a<=5;a++){for(b=1;b<=5;b++) { for(c=1;c<=5;c++) { if(a!=b&&a!=c&&b!=c 阅读全文
posted @ 2023-04-15 11:48 jmhyyds 阅读(22) 评论(0) 推荐(0)
摘要: 源码: #include <iostream>using namespace std;int main(){ int m,g,x;//m:母鸡,g:公鸡,x:小鸡; for(m=0;m<=33;m++) { for(g=0;g<=20;g++) { for(x=0;x<100;x++) { if(x 阅读全文
posted @ 2023-04-14 20:12 jmhyyds 阅读(65) 评论(0) 推荐(0)