Tugas2.2

Run Settings
LanguageC++
Language Version
Run Command
#include <iostream> using namespace std; int main() { //Yazid Rizqi //3420230012 //Teknik Informatika semester 3 int absen, tugas, uts, uas; float total; cout<<"---------------------------------"<<endl; cout<<" Program menghitung Nilai Akhir"<<endl; cout<<"---------------------------------"<<endl; printf("Masukkan nilai absen (10%): "); scanf("%d",&absen); printf("\nMasukkan nilai tugas (20%): "); scanf("%d",&tugas); printf("\nMasukkan nilai UTS (30%): "); scanf("%d",&uts); printf("\nMasukkan nilai UAS (40%): "); scanf("%d",&uas); cout<<endl; total = (absen * 0.1) + (tugas * 0.2) + (uts * 0.3) + (uas * 0.4); cout<<"---------------------------------"<<endl; printf("Nilai total adalah : %.2f", total); cout<<endl; cout<<"---------------------------------"<<endl; return 0; }
Editor Settings
Theme
Key bindings
Full width
Lines