Home
(current)
About
Tutorial
Technologies
C#
Deep Learning
Statistics for AIML
Natural Language Processing
Machine Learning
SQL -Structured Query Language
Python
Ethical Hacking
Placement Preparation
Quantitative Aptitude
View All Tutorial
Quiz
C#
SQL -Structured Query Language
Quantitative Aptitude
Java
View All Quiz Course
Q & A
C#
Quantitative Aptitude
Java
View All Q & A course
Programs
Articles
Identity And Access Management
Artificial Intelligence & Machine Learning Project
How to publish your local website on github pages with a custom domain name?
How to download and install Xampp on Window Operating System ?
How To Download And Install MySql Workbench
How to install Pycharm ?
How to install Python ?
How to download and install Visual Studio IDE taking an example of C# (C Sharp)
View All Post
Tools
Program Compiler
Sql Compiler
Replace Multiple Text
Meta Data From Multiple Url
Contact
User
Login
Register
FRESHER BELL ALL LANGUAGE ONLINE COMPILER
Java Program to print a input entered by user
Languages
Java
C
C-99
C++
C++ 14
C++ 17
PHP
Perl
Python 2
Python 3
Ruby
Go Lang
Scala
Bash Shell
SQL
Pascal
C#
VB.NET
Haskell
Objective C
Swift
Groovy
Fortran
Brainf**k
Lua
TCL
Hack
Rust
D
Ada
R Language
Free Basic
Theme
github
xcode
ambiance
monokai
chaos
chrome
Program
import java.util.Scanner; public class PrintValue { public static void main(String[] args) { Scanner s = new Scanner(System.in); System.out.println("Enter a Integer Value: "); int int1 = s.nextInt(); System.out.println("Enter a Float Value: "); float float2 = s.nextFloat(); System.out.println("Enter a Double Value: "); double double3 = s.nextDouble(); System.out.println("Enter a Long Value: "); long long4 = s.nextLong(); System.out.println("Enter a Short Value: "); short short5 = s.nextShort(); System.out.println("Enter a Boolean Value: "); boolean boolean6=s.nextBoolean(); System.out.println("Enter a Character Value: "); char char7=s.next().charAt(0); System.out.println("Enter a String Value:(only one word "); String str8 = s.next(); System.out.println("Enter a Integer Value: (Multiple Line)"); String str9 = s.nextLine(); System.out.println("You entered: Integer " + int1 ); System.out.println(" Float "+ float2 ); System.out.println(" Double "+ double3 ); System.out.println(" Long "+ long4 ); System.out.println(" Short "+ short5 ); System.out.println(" boolean "+ boolean6 ); System.out.println(" char "+ char7 ); System.out.println(" String1 "+ str8 ); System.out.println(" String2 "+ str9); } }
Run
Clear
Input
2 2.0 2.03 12299339939 3333 True f fresherbell Welcome to fresher bell
Output
Powered By Fresher Bell™
Similar Program
#
Program
Language
1
Java program to remove whitespaces from the string
Java
2
Java Logical And Operator Example
Java
3
Write a program to find time using battery capacity and changing current value
Java
4
Java program to find the sum of natural number using recursion
Java
5
Java program to generate pattern of Equilateral triangle or full pyramid using the number and for loop
Java
6
Java program to generate left angled triangle or left half pyramid using number and for loop
Java
7
Java Program to convert Character to String
Java
8
Java program to show factor of a user input
Java
9
Alternate Method: Write a java program to find the lcm .Given input in the form of day interval of dinner. Find the day on which they both will lunch together / dinner together.
Java
10
Java program to find LCM of two number taken by user using while loop
Java
11
Write a java program to determine whether a given number is a Harshad number
Java
12
Java if else condition example 2
Java
13
Java program to generate right angled triangle or half pyramid using alphabet and for loop
Java
14
Java program to find the ASCII value of a input taken from user
Java
15
Java Program to Find the Largest Among Three Numbers using input taken from users- (nested-if-else)
Java
16
Java program to find the reverse of user input
Java
17
Java Right Shift Operator Example
Java
18
Write a program if length of string is even, the reverse the string: MIDDLE LETTER/Reverse first half of the string if string length is ODD
Java
19
Java Bitwise And Operator Example
Java
20
Java Arithmetic Operator Program
Java
#
Program
Language
Copyright © 2020
Inovatik
- All rights reserved