Last active
January 20, 2022 21:28
-
-
Save smyy96/0eb2e32807a21c97261e9191aaeef3ba to your computer and use it in GitHub Desktop.
Patika Java101 dersi KDV Hesaplama - Patika Java 101 lesson VAT Calculation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.Scanner; | |
public class KDV { | |
public static void main(String[] args) { | |
//KDV Hesaplama - KDV Calculation | |
Scanner input= new Scanner(System.in); | |
double total=0, kdv=0; | |
System.out.println("Enter the fee amount:"); | |
total=input.nextDouble(); | |
kdv=total; | |
if (total<=1000 && total>0) | |
{ | |
kdv += (total*0.18); | |
System.out.println("Price: "+total+" KDV %18: "+kdv); | |
} | |
else{ | |
kdv += (total*0.8); | |
System.out.println("Price: "+total+" KDV %8: "+kdv); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment