2
Reply

make a figure

Bing In

Bing In

Apr 8 2016 8:30 AM
320
output the below figure typed from a student`s ID number(int),name(char),mid term exam score(int),final exam score(int),mid+final score(int),mid+final score average(int), grade(char)
 
but grade is decided by average score (from 10 to 59 : F, 60~69 :  D, 70~79 : C, 80~89 : B, 90~100 : A)
 
only if statements are used
 
help edit my code 
 
*************************************************************
 student`s number | name | mid exam | final exam | total score | average score | grade 
 
*************************************************************
      4241345***       Joe        94              90             184             92             A 
 
 

using System;
class example11
{
public static void Main()
{
int a = Console.Read(); 
string b = Console.Read();
int c = Console.Read();
int d = Console.Read();
int e = Console.Read();
int f = Console.Read();
char g = Console.Read();
Console.WriteLine("************************************************************); 
Console.WriteLine("student`s number | name | mid exam | final exam | total score | average score | grade ");
Console.WriteLine("***********************************************************"); 
Console.WriteLine("    4241345***           Joe             94                90                 184                         92                   A"); 
if (90 < &&  < 100) 
{
Console.WriteLine(a);
Console.WriteLine(b);
Console.WriteLine(c);
Console.WriteLine(d);
Console.WriteLine(e);
Console.WriteLine(f);
Console.WriteLine(g); 
}
else if (80 <  &&  < 89) 
{
}
else if (70 <  &&  < 79) 
{
}
else if (60 <  &&  < 69) 
{
}
else if (0 <  &&  < 59) 
{
}
}
}

Answers (2)