Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

import java.util.Scanner; public class LabProgram { public static void main ( String [ ] args ) { Scanner scnr = new Scanner ( System .

import java.util.Scanner;
public class LabProgram {
public static void main(String[] args){
Scanner scnr = new Scanner(System.in);
int num1;
int num2;
int num3;
int num4;
num1= scnr.nextInt();
num2= scnr.nextInt();
num3= scnr.nextInt();
num4= scnr.nextInt();
System.out.println((num1* num2* num3* num4)+""+(num1+ num2+ num3+ num4)/4+"");
double n1= num1;
double n2= num2;
double n3= num3;
double n4= num4;
System.out.printf("%.3f %.3f",(n1* n2* n3* n4),(n1+ n2+ n3+ n4)/4);
}
}

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Concepts of Database Management

Authors: Philip J. Pratt, Joseph J. Adamski

7th edition

978-1111825911, 1111825912, 978-1133684374, 1133684378, 978-111182591

More Books

Students also viewed these Databases questions

Question

When does a cost become an expense? Do all costs become expenses?

Answered: 1 week ago

Question

What are the stages of project management? Write it in items.

Answered: 1 week ago