2 条题解

  • 0
    @ 2023-9-10 15:30:28

    这是我的代码,可复制

    /****************************************
    Note:
    ****************************************/
    #include <queue>
    #include <math.h>
    #include <stack>
    #include <vector>
    #include <stdio.h>
    #include <iostream>
    #include <vector>
    #include <iomanip>
    #include <string.h>
    #include <cstring>
    #include <algorithm>
    #define int long long
    using namespace std;
    const int N = 1e6 + 10;
    const int INF = 0x3f3f3f3f;
    int n;
    signed main(){
    cin >> n;
    cout << n * 2 << endl;
    for(int i=1;i<=n/2;i++){
    if(n % i == 0) cout << i << " ";
    }
    cout << endl;
    return 0;
    }
    
    
    
    • 0
      @ 2023-4-1 22:00:21
      #include<iostream>
      using namespace std;
      int n;
      int main(){
      	cin>>n;
      	cout<<n*2<<endl;
      	for(int i=1;i*2<=n;i++){
      		if(n%i==0)cout<<i<<" ";
      	}
      	return 0;
      }
      
      • 1

      寻找某一个数字的倍数与因子

      信息

      ID
      1419
      时间
      1000ms
      内存
      128MiB
      难度
      9
      标签
      递交数
      8
      已通过
      8
      上传者