Java Tutorial 7 - Built-in Advanced Math Functions

preview_player
Показать описание
Java Tutorial 7

After this video, you'll be able to know how to use the power, square root, etc. The next video tutorial will be over user input for the advance math functions.
Рекомендации по теме
Комментарии
Автор

You are SUPER good at detailed explanation that often gets OVERLOOKED - grateful for you and your channel <3

thesockshow
Автор

@flyleb This code right here works. You have to make the min and max equations like this:

import java.lang.Math;
import java.util.Scanner;

public class Max
{
public static void main(String[] args)
{
Scanner kb = new Scanner(System.in);

System.out.println("Type in two numbers: ");

double x = kb.nextDouble();
double y = kb.nextDouble();

double z = Math.max(x, y);

System.out.println("Max: " + z);

double a = Math.min(x, y);

System.out.println("Min: " + a);
}
}

JohnGizdich
Автор

@flyleb Those two variables can work with 2 or more equations just like the code I've posted above. If you want to have a min AND max, then you'll need a min and max equations. I hope this helps. And btw sorry how the code is all bunched up together like that.

JohnGizdich
Автор

@flyleb Any time :) And thanks for subscribing

JohnGizdich
Автор

this one..i dont understand?can you help...i dont understand the Math.Pow part.How is it work?

moovy
join shbcf.ru