Skip to content

Instantly share code, notes, and snippets.

Created Aug 27, 2021
What would you like to do?
#include <iostream>
using namespace std;
int main(){
int number;
int i;
cout << "Enter a number : ";
for(i = 1; i <= number; ++i){
if(number % i == 0)
cout <<i<<endl;
return 0;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment