Raj
BAN USER
Comments (5)
Reputation -5
Page:
1
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
-1
of 1 vote
if we use kill process id,it will send SIGKILL command...to that process,if any signal handler is there...then that get caught by signal handler and program/process wont be killed.
kill -9 does not care about any signal handler ..it direct kill program/process.
kill -6 same as kill
Page:
1
CareerCup is the world's biggest and best source for software engineering interview preparation. See all our resources.
The easiest solution:
- Raj June 05, 2012int main(){
int coin_Avilabe[]={10,5,2,1};
int total_amount;
int mod=0;
int i=0;
int countOfCoin;
cout<<"please enter the total amount"<<endl;
cin>>total_amount;
while(total_amount){
countOfCoin=total_amount/coin_Avilabe[i];
total_amount=total_amount%coin_Avilabe[i];
if(countOfCoin)
cout<<"number of coin of require of "<<countOfCoin<<":"<<coin_Avilabe[i]<<endl;
i++;
}
}