Algoritmalar ve Programlama – 1 (Güz-2017) Hafta – 6

#include <iostream>
using namespace std;

int main()
{
    int dogru=0, yanlis=0;
    string secim;

    cout<<"1) 2 MB = ? KB"<<endl;
    cout<<"a) 10 b) 200 c) 2048 d) 4096"<<endl;
    cin>>secim;
    if(secim=="c")
        dogru=dogru+1;
    else
        yanlis=yanlis+1;

    cout<<"2) Asagidakilerden hangisi giris birimidir?"<<endl;
    cout<<"a) Monitor b) Klavye c) Kasa d) Yazici"<<endl;
    cin>>secim;
    if(secim=="b")
        dogru++;
    else
        yanlis++;

    cout<<"3) Asagidakilerden hangisi bir lojik kapı degildir?"<<endl;
    cout<<"a) AND b) OR c) XOR d) COR"<<endl;
    cin>>secim;
    if(secim=="d")
        dogru++;
    else
        yanlis++;

    cout<<"4) Asagidakilerden hangisi derlenen bir dildir?"<<endl;
    cout<<"a) C++ b) PHP c) PERL d) ASP"<<endl;
    cin>>secim;
    if(secim=="a")
        dogru++;
    else
        yanlis++;

    cout<<"5) C++ dilinde hangisi ekrana metin yazdirir?"<<endl;
    cout<<"a) cin b) int c) cout  d) if "<<endl;
    cin>>secim;
    if(secim=="c")
        dogru++;
    else
        yanlis++;

    cout<< "Toplam Dogru: "<<dogru<<" Toplam Yanlis: "<<yanlis<<endl;

    return 0;
}

 

Share