Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //practice
- #include <iostream>
- using namespace std;
- int main ()
- {
- int n;
- int number[100];
- for (int i=0; i<=99; i=i+1){
- number[i]=4*i+10;
- }
- for (int i=0; i<=99; i=i+1){
- cout<<"\nInput a number:"; cin>>n;
- if (number[i]==n)
- cout<<"number["<<i<<"]";
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement