We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
#include<iostream>#include<cstdio>usingnamespacestd;intmain(){// Complete the code.stringayam[]{"zero","one","two","three","four","five","six","seven","eight","nine",};inta,b;cin>>a>>b;for(inti=a;i<b+1;i++){if(i<=9){cout<<ayam[i]<<endl;}else{if(i>9&&i%2==0){cout<<"even"<<endl;}else{cout<<"odd"<<endl;}}}return0;}
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
For Loop
You are viewing a single comment's thread. Return to all comments →