Sourya Saha
Java Datatype
1 Answer(s)      9 months ago
Posted in : Java Beginners

What will be the output of following java program and why?

class Datatype{ public static void main(String[] args){ byte number=0101; System.out.print(number); } }

View Answers

August 27, 2012 at 12:29 PM


The given code displays the output 65. The value stored in byte is binary number. Therefore it displays its corresponding integer value.

class Datatype{
     public static void main(String[] args){
          byte number=0101;
          System.out.print(number);
     }
}









Related Pages:
Datatype convertion
Datatype convertion  it possible to convert long datatype into string in java if possible means how
Java Datatype
Java Datatype  What will be the output of following java program and why? class Datatype{ public static void main(String[] args.... Therefore it displays its corresponding integer value. class Datatype{ public
Boolean DataType
Boolean DataType  What is the Size of the Boolean datatype in Java
Java Datatype
Java Datatype  What will be the output of following java program and why? class Datatype{ public static void main(String[] args.... Therefore it displays its corresponding integer value. class Datatype{ public
Java Primitive Datatype
Java Primitive Datatype  what is the size of boolean datatype ? please explain in detail
Java String Datatype
Java String Datatype  Weather String in java is class or Datatype,if it's clss then How can i assign String str="hello";   String is a class found in the package java.lang.*. When we represent string in double quotes
datatype - Java Beginners
datatype  how i convert char datatype in string format for ex.(convertion of int datatype) int variable_name=Integer.parseInt(br.readLine());  Hi Friend, Try the following code: import java.io.*; public class
Writing a trigger for an userdefined datatype
Writing a trigger for an userdefined datatype  i have a user defined datatype in EMP table like COLUMNNAME:ADDRS_TYPE where ADDRS_TYPE have the following columns DATATYPE :ADDRESS VARCHAR2(136) V_CODE VARCHAR2(8) T_CODE
Java - Identifier and primitive datatype in java
Java - Identifier and Primitive Data Types in java  ... you how to use these identifier in you  java programming. Identifier... stored by identifier is defined by the special java keyword is termed
Mysql Alter Column Datatype
Mysql Alter Column Datatype       Mysql Alter Column Datatype is used to modify the table and change the datatype of field. Understand with Example The Tutorial illustrate an example
Mysql Decimal Datatype
Mysql Decimal Datatype       Mysql Decimal Datatype is used to specify the numeric values. Understand with Example The Tutorial give you an example from 'Mysql Decimal Datatype
Mysql nchar Datatype
Mysql nchar Datatype       MySQL nchar define the datatype nchar that stores fixed-length character data. The data can be a string single-byte or multibyte letters, digits
Java Methods
Java Methods      ... of operator returns the datatype of an operand. You can see in the given example....    In Java, java.lang.reflect.*; package
how to use float datatype in mysql? - SQL
how to use float datatype in mysql?  how to use float datatype in mysql?  hi Chitra this code help u CREATE TABLE `paging` ( `Id` float(10,2) NOT NULL default '0.00', `name` varchar(255) default NULL
Java - Arithmetic Operation, Conversion and Casts in java
Java - Arithmetic Operation, Conversion and Casts in java       This example illustrates that what is type casting? Type Casting  refers to changing an entity of one datatype
java
java  how to identify method,attribute,variable,datatype,object in java program?give the explanation with program
SQL Decimal
SQL Decimal       SQL Decimal is used to specify the values in decimal datatype. The Decimal datatype can be of two types : Decimal (p) refers to floating point and Decimal fixed
Data Type: bool
Data Type: bool       This Example shows you how to use bool datatype in velocity. Methods... a boolean datatype variable. $bool: Display boolean datatype variable
Roshni
Datatype in SQL  when we want store image which datatype is used in mysql?   You can use blob, longblob datatype to store image into mysql database. Java Store Image into MySQL
Mysql Alter Data Type
datatype in a table. Understand with Example The Tutorial cover an example on 'Mysql...' with required fieldname and datatype respectively.The table 'userform' has a  ID... the  column datatype from "contact( bigint)" to contact(varchar
Casting in java - Java Beginners
. Upcasting : lower datatype to higher ex: int i; float j=i... is this correct but i cant understand datatype(Upcasting ) compared...: http://www.roseindia.net/java/java-exception/cast-exception.shtml http
MySQL nchar
MySQL nchar       MySQL nchar define the datatype nchar that stores fixed-length character data. The data can be a string single-byte or multibyte letters, digits and symbols
java servlet programming - JDBC
java servlet programming  how to insert value in a column of datatype - datetime in sql 2000 using java servlets???? can ne 1 help me out???  Hi neepa, you have to put the datetime in single quotes. For ex
java preface - Java Beginners
is very flexible in datatype(loosly typed). Ex : Variables in Java...) Java support function declarations, with access specifiers,parameter datatype...java preface  what is difference between java programming language
HIiiiiiiii - Java Beginners
datatype definition... look at the part of the code given ..... while(rst.next...;% } here u must give the correct datatype according to each column of ur table...? 6th varchar? 7th int? you must give the correct datatype according
java - Java Beginners
the values into string array datatype dynamically   Hi friend...]); } } } ------------------------------- Read for more information. http://www.roseindia.net/java
comparision between database's datetime field and systemdate of java application - Java Beginners
comparision between database's datetime field and systemdate of java application  Hi All, I have a database table which contains datetime as datatype. I have to retrieve that field and compare it with system time. i.e.
java servlet programming - JSP-Servlet
java servlet programming  when i m inserting an image file into the sql table in a column of data type binary using prepared statement... in the column of datatype binary
Roshni
MYSQL datatype to store image into database  when we want store image which datatype is used in mysql?   You can use blob, longblob datatype to store image into mysql database. Java Store Image into MySQL
Roshni
Datatype for image in SQL  when we want store image which datatype is used in mysql?   You can use blob, longblob datatype to store image into mysql database. Java Store Image into MySQL
Mysql Table Describe
Mysql Table Describe       Mysql Table Describe is used to describe the Fieldtype, Datatype, Null and Key etc of the table. Understand with Example The Tutorial illustrate
java code - Java Beginners
java code  hi sir.. write a code in java for the password generator. when we run the code it should ask from user as follows .. input string : datatype of password : length of password : Enter password
Java - Java Beginners
Java difference between Array and Vector  What is the difference between Array and Vector in Java?  DIFFERENCE... of same datatype belonging to a particular class. Array stores the values
Core Java - Java Beginners
Core Java  Hi Sir/Madam, Can u please explain about the Double in java. I have problem with Double datatype. public class DoubleTesting { public static void main(String[] args) { Double amt=137.17*100
servlets - Java Interview Questions
servlets  Good Evening. I want to work with BLOB datatype. I know only this datatype is used to store images other than this i dont know anything. now in my project i need to work with blob. so i want to upload image from
Java Compilation Error - Java Beginners
Java Compilation Error   Actually Iam having a packaging. Whatever... datatype but You declare String in Authors class Constructor : public Authors...; weight=w; } For any more information on Java visit to : http
What is difference between the java and javascript?
What is difference between the java and javascript?  What is the difference beteen the java and javascript?   Hello Friend, Difference: 1) Java is a Object Oriented programming language developed by Sun Microsystems
Mysql Alter Column
; Mysql Alter Column is used to redefine the table and change the datatype... create a table 'employee1' with required fieldname and datatype. Query to create... (0.00 sec) Query to view datatype of  Table named employee1
Mysql Create Table
. To grasp this example, we create a table 'Stu' with required fieldname and datatype
db error - Java Beginners
the datatype of the field in which you are inserting your text area content. if you are using mysql then put the datatype as "longtext". repply your...' or 'longtext' datatype for the textarea field in the database table. Thanks
Doubt on Data Types - Java Beginners
to put it in java.  If you want to declare a decimal value in Java, it will be considered as double datatype by default. So to specifically mention a float datatype value you should add character 'f' or 'F' at the end of the value
Roshni
Store Image into Database  when we want store image which datatype is used in mysql?   You can use blob, longblob datatype to store image into mysql database. Java Store Image into MySQL
Roshni
Database to store image  when we want store image which datatype is used in mysql?   You can use blob, longblob datatype to store image into mysql database. Java Store Image into MySQL
program code - Java Server Faces Questions
datatype. Button:-save,cancel,exit todate is taken from the server.fromdate.... ie.lists of date between the fromdate and todate with datatype datetime can
Mysql Date Search
Mysql Date Search       In this Tutorial you will learn how to' search Date in Mysql'. To understand this example, we create a table 'employee' with required fieldname and datatype
JavaScript type of Operator
JavaScript type of Operator       The JavaScript type of operator returns the datatype of an operand. You can see in the given example that we have used different variables
coding problem - Java Beginners
coding problem  hi! i declared date as date datatype in oracle now i need to retrieve date from database to my java code.how can i please help me urgent   Hi Friend, We are providing you a code that will retrieve
jdbc
jdbc  if i create one table that consist of usename ,joiningdate for joining date i have used varchar datatype not date . then we store date into database table as a string by using java .then what are the drawbacks
JAVA(JDBC) - JDBC
JAVA(JDBC)  Hello friends, please tel me, how can we retrieve the stored images, form the oracle table. for example, in case of String String str.......... A simple method is just store the complete path of the image. Hence the datatype
Java arraylist int
feature primitive datatype gets autoboxed into Wrapper class object.... Example of Java Arraylist int import java.util.ArrayList; import java.util.List