Ceriwis  

Go Back   Ceriwis > HOBI > Komputer & Teknologi > Programming

Programming Share, tanya jawab, saling bantu antar programmer dengan berbagai macam bahasa pemrograman.

Reply
 
Thread Tools
  #1  
Old 20th November 2011
Permenkaret Permenkaret is offline
Ceriwiser
 
Join Date: Nov 2011
Posts: 351
Rep Power: 15
Permenkaret mempunyai hidup yang Normal
Default [ASK]ada error nih diprogram C ane

nih kode2nya


Code:

#include
#include
#include
#include
#include
#include
void main() {
awal:
clrscr();
char A;
string L;
coutA;
if(isdigit(A)) {
printf("inputan anda adalah numeric\n");
}
if(isalpha(A)) {
printf("inputan anda adalah bukan numeric\n");
}
akhir:
coutL;
if(L=="Y" || L =="y"){
goto awal;
}
if(L=="N" || L=="n"){
printf("Selesai");
}
else
goto akhir;
}

itu niatnya ane pengen saat program berakhir dia bakal muncul pertanyaan untuk mengulang kembali ato gak tapi pas ane jalanin kok pertanyaannya muncul sebanyak 2 kali kalo jumlah inputannya lebih dari sekali

misalnya inputannya "12","123","1234",dst nanti munculnya pertanyaannya 2 kali

kalo inputannya "1","2","3",dst nanti pertanyaanya jadi sekali doang

nah ane pengennya muncul pertanyaannya sekali aja walaupun inputannya lebih dari sekali

mohon bantuannya dong mastah2

</div>
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Terkait
Thread Thread Starter Forum Replies Last Post
JUAL Service ERROR 99, AF matot, ERROR 02, ERROR 01 [ Bandung ] weddingshooter Kamera & Aksesoris 0 29th August 2012 11:07 PM
robot stik eskrim diprogram siswa SD gan ! aziskentut Jokes 0 9th June 2012 09:31 AM
TOSHIBA NB200, LCD garis 1, Keyboard error. pointer error. batre error. laptopgaul Notebook 0 8th June 2012 02:36 PM
JUAL TOSHIBA NB200, LCD garis 1, Keyboard error. pointer error. batre error. newsamsung Notebook 0 8th June 2012 01:49 PM
Game Komputer Tertua Diprogram Ulang baksourat Lounge 0 27th May 2012 03:40 PM

 


All times are GMT +7. The time now is 02:17 PM.