Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

please use Kotlin code Objectives: Write a Kotlin code that uses user input then makes a decision to display an output Imagine that you are

please use Kotlin code
image

Objectives: Write a Kotlin code that uses user input then makes a decision to display an output Imagine that you are a nutritionist, Write a Kotlin code to find out your costumers BMI: 1.Ask the user to input his name 2.Ask the user to input his height in meters 3.Ask the user to input his weight in kilograms 4. Use a function to calculate his BMI using: BMI = weight / (height x height) 5.Then check: - If his BMI is more than 30, then display his name, BMI value and the result: Obesity - Otherwise, if his BMI is more than 25, then display his name, BMI value and the result: Overweight - Otherwise, if his BMI is more than 18, then display his name,BMI value and the result: Normal - Otherwise display then display her name, BMI value and the result: Underweight

Step by Step Solution

3.44 Rating (163 Votes )

There are 3 Steps involved in it

Step: 1

answer fun main printlnWhat is your name val name readLine printlnWhat is your height in meters val ... 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

Systems analysis and design

Authors: kenneth e. kendall, julie e. kendall

8th Edition

135094909, 013608916X, 9780135094907, 978-0136089162

More Books

Students also viewed these Programming questions

Question

e. What are the programs research and clinical focus areas?

Answered: 1 week ago

Question

What does a process represent on a context-level data flow diagram?

Answered: 1 week ago