Syncfusion Interview Question

Simple pgm to calculate cutoff marks

Interview Answers

Anonymous

Jun 20, 2015

Proceed with given formula

7

Anonymous

Oct 19, 2015

Answer of this program in c++ #include int main() { float maths,chemistry,physics,cutoff; cout>maths; cout>chemistry; cout>physics; maths=maths*0.5; chemistry=chemistry*0.25; physics=physics*0.25; cutoff=maths+chemistry+physics; cout<<"The cutoff value is : "<

Anonymous

Oct 19, 2015

import java.io.*; public class Cutoff { /** * @param args */ public static void main(String[] args)throws IOException { // TODO Auto-generated method stub float chemistry,physics,maths; Double cutoff; String str; DataInputStream in= new DataInputStream(System.in); System.out.println("Enter the chemistry marks out of 200:"); str=in.readLine(); chemistry=Integer.parseInt(str); System.out.println("Enter the physics marks out of 200:"); str=in.readLine(); physics=Integer.parseInt(str); System.out.println("Enter the maths marks out of 200:"); str=in.readLine(); maths=Integer.parseInt(str); maths=(float)(maths*0.5); physics=(float)(physics*0.25); chemistry=(float)(chemistry*0.25); cutoff=(double)(maths+physics+chemistry); System.out.println("The cutoff value is:"+cutoff); } }

1