SlideShare une entreprise Scribd logo
1  sur  2
Télécharger pour lire hors ligne
//Ques. 7 WAP to demonstrate type conversions ( int to byte, double to int,
double to byte ).

class conversion
{
public static void main(String arr[])
{
byte b;
inti = 257;
double d = 323.142;
System.out.println(" n Conversion of int to byte: ");
b= (byte) i;
System.out.print(" i = "+i+ " b = "+b);
System.out.println("n n Conversion of double to int: ");
i= (int) d;
System.out.print(" d = "+d+ " i = "+i);
System.out.println("n n Conversion of double to byte: ");
b= (byte) d;
System.out.println(" d = "+d+ " b = "+b);
}
}
OUTPUT:-

Contenu connexe

Tendances

Community-driven Language Design at TC39 on the JavaScript Pipeline Operator ...
Community-driven Language Design at TC39 on the JavaScript Pipeline Operator ...Community-driven Language Design at TC39 on the JavaScript Pipeline Operator ...
Community-driven Language Design at TC39 on the JavaScript Pipeline Operator ...Igalia
 
2 19-2018-mean of all runs
2 19-2018-mean of all runs2 19-2018-mean of all runs
2 19-2018-mean of all runsAlexander Bitar
 
Assignment#1
Assignment#1Assignment#1
Assignment#1NA000000
 
Dynamic Program Problems
Dynamic Program ProblemsDynamic Program Problems
Dynamic Program ProblemsRanjit Sasmal
 
Probability of finding a single qubit in a state
Probability of finding a single qubit in a stateProbability of finding a single qubit in a state
Probability of finding a single qubit in a stateVijayananda Mohire
 
FlexClock, a Plastic Clock Written in Oz with the QTk toolkit
FlexClock, a Plastic Clock Written in Oz with the QTk toolkitFlexClock, a Plastic Clock Written in Oz with the QTk toolkit
FlexClock, a Plastic Clock Written in Oz with the QTk toolkitJean Vanderdonckt
 
Jarmo van de Seijp Shadbox ERC223
Jarmo van de Seijp Shadbox ERC223Jarmo van de Seijp Shadbox ERC223
Jarmo van de Seijp Shadbox ERC223Jarmo van de Seijp
 
D vs OWKN Language at LLnagoya
D vs OWKN Language at LLnagoyaD vs OWKN Language at LLnagoya
D vs OWKN Language at LLnagoyaN Masahiro
 
All you need to know about Callbacks, Promises, Generators
All you need to know about Callbacks, Promises, GeneratorsAll you need to know about Callbacks, Promises, Generators
All you need to know about Callbacks, Promises, GeneratorsBrainhub
 

Tendances (19)

Ooprc3c
Ooprc3cOoprc3c
Ooprc3c
 
Community-driven Language Design at TC39 on the JavaScript Pipeline Operator ...
Community-driven Language Design at TC39 on the JavaScript Pipeline Operator ...Community-driven Language Design at TC39 on the JavaScript Pipeline Operator ...
Community-driven Language Design at TC39 on the JavaScript Pipeline Operator ...
 
2 19-2018-mean of all runs
2 19-2018-mean of all runs2 19-2018-mean of all runs
2 19-2018-mean of all runs
 
Assignment#1
Assignment#1Assignment#1
Assignment#1
 
Experement no 6
Experement no 6Experement no 6
Experement no 6
 
Dynamic Program Problems
Dynamic Program ProblemsDynamic Program Problems
Dynamic Program Problems
 
C# Assignmet Help
C# Assignmet HelpC# Assignmet Help
C# Assignmet Help
 
Tools.cpp
Tools.cppTools.cpp
Tools.cpp
 
program on Function overloading in java
program on  Function overloading in javaprogram on  Function overloading in java
program on Function overloading in java
 
Bubble in link list
Bubble in link listBubble in link list
Bubble in link list
 
Probability of finding a single qubit in a state
Probability of finding a single qubit in a stateProbability of finding a single qubit in a state
Probability of finding a single qubit in a state
 
Logging in JavaScript - Part-3
Logging in JavaScript - Part-3Logging in JavaScript - Part-3
Logging in JavaScript - Part-3
 
Single qubit-gates operations
Single qubit-gates operationsSingle qubit-gates operations
Single qubit-gates operations
 
FlexClock, a Plastic Clock Written in Oz with the QTk toolkit
FlexClock, a Plastic Clock Written in Oz with the QTk toolkitFlexClock, a Plastic Clock Written in Oz with the QTk toolkit
FlexClock, a Plastic Clock Written in Oz with the QTk toolkit
 
Jarmo van de Seijp Shadbox ERC223
Jarmo van de Seijp Shadbox ERC223Jarmo van de Seijp Shadbox ERC223
Jarmo van de Seijp Shadbox ERC223
 
Practical no 2
Practical no 2Practical no 2
Practical no 2
 
D vs OWKN Language at LLnagoya
D vs OWKN Language at LLnagoyaD vs OWKN Language at LLnagoya
D vs OWKN Language at LLnagoya
 
All you need to know about Callbacks, Promises, Generators
All you need to know about Callbacks, Promises, GeneratorsAll you need to know about Callbacks, Promises, Generators
All you need to know about Callbacks, Promises, Generators
 
Sol10
Sol10Sol10
Sol10
 

En vedette

Capacitación a jóvenes del viii ciclo
Capacitación a jóvenes del viii cicloCapacitación a jóvenes del viii ciclo
Capacitación a jóvenes del viii cicloPerpetua Yzquierdo
 
אומגה 3 קשב וריכוז
אומגה 3 קשב וריכוזאומגה 3 קשב וריכוז
אומגה 3 קשב וריכוזomega3 galil
 
Aquela mulher é a minha mãe!
Aquela mulher é a minha mãe!Aquela mulher é a minha mãe!
Aquela mulher é a minha mãe!bloggerfph
 
01 sueli da_rocha_pereira_lopes_-_v1_revisado[2]
01 sueli da_rocha_pereira_lopes_-_v1_revisado[2]01 sueli da_rocha_pereira_lopes_-_v1_revisado[2]
01 sueli da_rocha_pereira_lopes_-_v1_revisado[2]Ceila Coelho
 
Funções sintáticas
Funções sintáticasFunções sintáticas
Funções sintáticasbloggerfph
 
Presentaciòn herramientas
Presentaciòn herramientasPresentaciòn herramientas
Presentaciòn herramientasClaudia Ramírez
 
CLUSTER AHORRO - Software de gestión energética
CLUSTER AHORRO - Software de gestión energéticaCLUSTER AHORRO - Software de gestión energética
CLUSTER AHORRO - Software de gestión energéticaJoan Trilla Melé
 
Cel Nome - Bruno
Cel Nome - BrunoCel Nome - Bruno
Cel Nome - Brunobloggerfph
 
Actividades iniciales access
Actividades iniciales accessActividades iniciales access
Actividades iniciales accessrakelcos1996
 
ORGANIZACAO_DE_APRESENTACOES
ORGANIZACAO_DE_APRESENTACOESORGANIZACAO_DE_APRESENTACOES
ORGANIZACAO_DE_APRESENTACOESRobson Castro
 
Tube bending services
Tube bending servicesTube bending services
Tube bending servicesCharlesbab16
 
Infoprogramafutbol 130411112736-phpapp02
Infoprogramafutbol 130411112736-phpapp02Infoprogramafutbol 130411112736-phpapp02
Infoprogramafutbol 130411112736-phpapp02Johnny Paez
 
Video como recurso didacticos
Video como recurso didacticosVideo como recurso didacticos
Video como recurso didacticosnormabermudez
 
Actividades iniciales access
Actividades iniciales accessActividades iniciales access
Actividades iniciales accessrakelcos1996
 

En vedette (20)

Capacitación a jóvenes del viii ciclo
Capacitación a jóvenes del viii cicloCapacitación a jóvenes del viii ciclo
Capacitación a jóvenes del viii ciclo
 
Indicadores para la evaluación
Indicadores para la evaluaciónIndicadores para la evaluación
Indicadores para la evaluación
 
אומגה 3 קשב וריכוז
אומגה 3 קשב וריכוזאומגה 3 קשב וריכוז
אומגה 3 קשב וריכוז
 
Secuencia ordenada infd reina batata
Secuencia ordenada infd reina batataSecuencia ordenada infd reina batata
Secuencia ordenada infd reina batata
 
Six sigma
Six sigmaSix sigma
Six sigma
 
Aquela mulher é a minha mãe!
Aquela mulher é a minha mãe!Aquela mulher é a minha mãe!
Aquela mulher é a minha mãe!
 
01 sueli da_rocha_pereira_lopes_-_v1_revisado[2]
01 sueli da_rocha_pereira_lopes_-_v1_revisado[2]01 sueli da_rocha_pereira_lopes_-_v1_revisado[2]
01 sueli da_rocha_pereira_lopes_-_v1_revisado[2]
 
Funções sintáticas
Funções sintáticasFunções sintáticas
Funções sintáticas
 
Presentaciòn herramientas
Presentaciòn herramientasPresentaciòn herramientas
Presentaciòn herramientas
 
CLUSTER AHORRO - Software de gestión energética
CLUSTER AHORRO - Software de gestión energéticaCLUSTER AHORRO - Software de gestión energética
CLUSTER AHORRO - Software de gestión energética
 
Cel Nome - Bruno
Cel Nome - BrunoCel Nome - Bruno
Cel Nome - Bruno
 
Actividades iniciales access
Actividades iniciales accessActividades iniciales access
Actividades iniciales access
 
ORGANIZACAO_DE_APRESENTACOES
ORGANIZACAO_DE_APRESENTACOESORGANIZACAO_DE_APRESENTACOES
ORGANIZACAO_DE_APRESENTACOES
 
Tube bending services
Tube bending servicesTube bending services
Tube bending services
 
Webquest
WebquestWebquest
Webquest
 
Mi blogger
Mi bloggerMi blogger
Mi blogger
 
Infoprogramafutbol 130411112736-phpapp02
Infoprogramafutbol 130411112736-phpapp02Infoprogramafutbol 130411112736-phpapp02
Infoprogramafutbol 130411112736-phpapp02
 
Video como recurso didacticos
Video como recurso didacticosVideo como recurso didacticos
Video como recurso didacticos
 
Arte circense na escola
Arte circense na escolaArte circense na escola
Arte circense na escola
 
Actividades iniciales access
Actividades iniciales accessActividades iniciales access
Actividades iniciales access
 

Plus de One97 Communications Limited

WAP to invoke constructors using super keyword in java
WAP to invoke constructors using super keyword in javaWAP to invoke constructors using super keyword in java
WAP to invoke constructors using super keyword in javaOne97 Communications Limited
 
WAP to find out whether the number is prime or not in java
WAP to find out whether the number is prime or not in javaWAP to find out whether the number is prime or not in java
WAP to find out whether the number is prime or not in javaOne97 Communications Limited
 
How to achieve multiple inheritances by using interface in java
How to achieve multiple inheritances by using interface in java How to achieve multiple inheritances by using interface in java
How to achieve multiple inheritances by using interface in java One97 Communications Limited
 
WAP to implement inheritance and overloading methods in java
WAP to implement inheritance and overloading methods in javaWAP to implement inheritance and overloading methods in java
WAP to implement inheritance and overloading methods in javaOne97 Communications Limited
 
WAP to initialize different objects with different values in java
WAP to initialize different objects with different values in javaWAP to initialize different objects with different values in java
WAP to initialize different objects with different values in javaOne97 Communications Limited
 

Plus de One97 Communications Limited (20)

Er. Model Of Hospital Management
Er. Model Of Hospital ManagementEr. Model Of Hospital Management
Er. Model Of Hospital Management
 
Financial
FinancialFinancial
Financial
 
Railway
RailwayRailway
Railway
 
Library
LibraryLibrary
Library
 
Fcfs Cpu Scheduling With Gantt Chart
Fcfs Cpu Scheduling With Gantt ChartFcfs Cpu Scheduling With Gantt Chart
Fcfs Cpu Scheduling With Gantt Chart
 
Neural Interfacing
Neural Interfacing Neural Interfacing
Neural Interfacing
 
Blue eye technology
Blue eye technology Blue eye technology
Blue eye technology
 
Computer Forensics
Computer ForensicsComputer Forensics
Computer Forensics
 
Backtrack
BacktrackBacktrack
Backtrack
 
Protect Folders without using any Software
Protect Folders without using any SoftwareProtect Folders without using any Software
Protect Folders without using any Software
 
Introduction to Java Programming
Introduction to Java ProgrammingIntroduction to Java Programming
Introduction to Java Programming
 
Topology
TopologyTopology
Topology
 
WAP to invoke constructors using super keyword in java
WAP to invoke constructors using super keyword in javaWAP to invoke constructors using super keyword in java
WAP to invoke constructors using super keyword in java
 
WAP to find out whether the number is prime or not in java
WAP to find out whether the number is prime or not in javaWAP to find out whether the number is prime or not in java
WAP to find out whether the number is prime or not in java
 
Overriding abstract in java
Overriding abstract in javaOverriding abstract in java
Overriding abstract in java
 
How to achieve multiple inheritances by using interface in java
How to achieve multiple inheritances by using interface in java How to achieve multiple inheritances by using interface in java
How to achieve multiple inheritances by using interface in java
 
Method overriding in java
Method overriding in javaMethod overriding in java
Method overriding in java
 
WAP to implement inheritance and overloading methods in java
WAP to implement inheritance and overloading methods in javaWAP to implement inheritance and overloading methods in java
WAP to implement inheritance and overloading methods in java
 
Program on usage of Final keyword in java
Program on usage of  Final keyword in javaProgram on usage of  Final keyword in java
Program on usage of Final keyword in java
 
WAP to initialize different objects with different values in java
WAP to initialize different objects with different values in javaWAP to initialize different objects with different values in java
WAP to initialize different objects with different values in java
 

Dernier

Riti theory by Vamana Indian poetics.pptx
Riti theory by Vamana Indian poetics.pptxRiti theory by Vamana Indian poetics.pptx
Riti theory by Vamana Indian poetics.pptxDhatriParmar
 
DNA and RNA , Structure, Functions, Types, difference, Similarities, Protein ...
DNA and RNA , Structure, Functions, Types, difference, Similarities, Protein ...DNA and RNA , Structure, Functions, Types, difference, Similarities, Protein ...
DNA and RNA , Structure, Functions, Types, difference, Similarities, Protein ...AKSHAYMAGAR17
 
DLL Catch Up Friday March 22.docx CATCH UP FRIDAYS
DLL Catch Up Friday March 22.docx CATCH UP FRIDAYSDLL Catch Up Friday March 22.docx CATCH UP FRIDAYS
DLL Catch Up Friday March 22.docx CATCH UP FRIDAYSTeacherNicaPrintable
 
BBA 205 BUSINESS ENVIRONMENT UNIT I.pptx
BBA 205 BUSINESS ENVIRONMENT UNIT I.pptxBBA 205 BUSINESS ENVIRONMENT UNIT I.pptx
BBA 205 BUSINESS ENVIRONMENT UNIT I.pptxProf. Kanchan Kumari
 
Dhavni Theory by Anandvardhana Indian Poetics
Dhavni Theory by Anandvardhana Indian PoeticsDhavni Theory by Anandvardhana Indian Poetics
Dhavni Theory by Anandvardhana Indian PoeticsDhatriParmar
 
The basics of sentences session 8pptx.pptx
The basics of sentences session 8pptx.pptxThe basics of sentences session 8pptx.pptx
The basics of sentences session 8pptx.pptxheathfieldcps1
 
The OERs: Transforming Education for Sustainable Future by Dr. Sarita Anand
The OERs: Transforming Education for Sustainable Future by Dr. Sarita AnandThe OERs: Transforming Education for Sustainable Future by Dr. Sarita Anand
The OERs: Transforming Education for Sustainable Future by Dr. Sarita AnandDr. Sarita Anand
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (GLOB...
BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (GLOB...BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (GLOB...
BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (GLOB...Nguyen Thanh Tu Collection
 
BBA 205 BE UNIT 2 economic systems prof dr kanchan.pptx
BBA 205 BE UNIT 2 economic systems prof dr kanchan.pptxBBA 205 BE UNIT 2 economic systems prof dr kanchan.pptx
BBA 205 BE UNIT 2 economic systems prof dr kanchan.pptxProf. Kanchan Kumari
 
ICS2208 Lecture4 Intelligent Interface Agents.pdf
ICS2208 Lecture4 Intelligent Interface Agents.pdfICS2208 Lecture4 Intelligent Interface Agents.pdf
ICS2208 Lecture4 Intelligent Interface Agents.pdfVanessa Camilleri
 
30-de-thi-vao-lop-10-mon-tieng-anh-co-dap-an.doc
30-de-thi-vao-lop-10-mon-tieng-anh-co-dap-an.doc30-de-thi-vao-lop-10-mon-tieng-anh-co-dap-an.doc
30-de-thi-vao-lop-10-mon-tieng-anh-co-dap-an.docdieu18
 
LEAD6001 - Introduction to Advanced Stud
LEAD6001 - Introduction to Advanced StudLEAD6001 - Introduction to Advanced Stud
LEAD6001 - Introduction to Advanced StudDr. Bruce A. Johnson
 
Plant Tissue culture., Plasticity, Totipotency, pptx
Plant Tissue culture., Plasticity, Totipotency, pptxPlant Tissue culture., Plasticity, Totipotency, pptx
Plant Tissue culture., Plasticity, Totipotency, pptxHimansu10
 
3.14.24 Gender Discrimination and Gender Inequity.pptx
3.14.24 Gender Discrimination and Gender Inequity.pptx3.14.24 Gender Discrimination and Gender Inequity.pptx
3.14.24 Gender Discrimination and Gender Inequity.pptxmary850239
 
3.12.24 Freedom Summer in Mississippi.pptx
3.12.24 Freedom Summer in Mississippi.pptx3.12.24 Freedom Summer in Mississippi.pptx
3.12.24 Freedom Summer in Mississippi.pptxmary850239
 
THYROID HORMONE.pptx by Subham Panja,Asst. Professor, Department of B.Sc MLT,...
THYROID HORMONE.pptx by Subham Panja,Asst. Professor, Department of B.Sc MLT,...THYROID HORMONE.pptx by Subham Panja,Asst. Professor, Department of B.Sc MLT,...
THYROID HORMONE.pptx by Subham Panja,Asst. Professor, Department of B.Sc MLT,...Subham Panja
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (FRIE...
BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (FRIE...BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (FRIE...
BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (FRIE...Nguyen Thanh Tu Collection
 
Arti Languages Pre Seed Send Ahead Pitchdeck 2024.pdf
Arti Languages Pre Seed Send Ahead Pitchdeck 2024.pdfArti Languages Pre Seed Send Ahead Pitchdeck 2024.pdf
Arti Languages Pre Seed Send Ahead Pitchdeck 2024.pdfwill854175
 
VIT336 – Recommender System - Unit 3.pdf
VIT336 – Recommender System - Unit 3.pdfVIT336 – Recommender System - Unit 3.pdf
VIT336 – Recommender System - Unit 3.pdfArthyR3
 
EDD8524 The Future of Educational Leader
EDD8524 The Future of Educational LeaderEDD8524 The Future of Educational Leader
EDD8524 The Future of Educational LeaderDr. Bruce A. Johnson
 

Dernier (20)

Riti theory by Vamana Indian poetics.pptx
Riti theory by Vamana Indian poetics.pptxRiti theory by Vamana Indian poetics.pptx
Riti theory by Vamana Indian poetics.pptx
 
DNA and RNA , Structure, Functions, Types, difference, Similarities, Protein ...
DNA and RNA , Structure, Functions, Types, difference, Similarities, Protein ...DNA and RNA , Structure, Functions, Types, difference, Similarities, Protein ...
DNA and RNA , Structure, Functions, Types, difference, Similarities, Protein ...
 
DLL Catch Up Friday March 22.docx CATCH UP FRIDAYS
DLL Catch Up Friday March 22.docx CATCH UP FRIDAYSDLL Catch Up Friday March 22.docx CATCH UP FRIDAYS
DLL Catch Up Friday March 22.docx CATCH UP FRIDAYS
 
BBA 205 BUSINESS ENVIRONMENT UNIT I.pptx
BBA 205 BUSINESS ENVIRONMENT UNIT I.pptxBBA 205 BUSINESS ENVIRONMENT UNIT I.pptx
BBA 205 BUSINESS ENVIRONMENT UNIT I.pptx
 
Dhavni Theory by Anandvardhana Indian Poetics
Dhavni Theory by Anandvardhana Indian PoeticsDhavni Theory by Anandvardhana Indian Poetics
Dhavni Theory by Anandvardhana Indian Poetics
 
The basics of sentences session 8pptx.pptx
The basics of sentences session 8pptx.pptxThe basics of sentences session 8pptx.pptx
The basics of sentences session 8pptx.pptx
 
The OERs: Transforming Education for Sustainable Future by Dr. Sarita Anand
The OERs: Transforming Education for Sustainable Future by Dr. Sarita AnandThe OERs: Transforming Education for Sustainable Future by Dr. Sarita Anand
The OERs: Transforming Education for Sustainable Future by Dr. Sarita Anand
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (GLOB...
BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (GLOB...BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (GLOB...
BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (GLOB...
 
BBA 205 BE UNIT 2 economic systems prof dr kanchan.pptx
BBA 205 BE UNIT 2 economic systems prof dr kanchan.pptxBBA 205 BE UNIT 2 economic systems prof dr kanchan.pptx
BBA 205 BE UNIT 2 economic systems prof dr kanchan.pptx
 
ICS2208 Lecture4 Intelligent Interface Agents.pdf
ICS2208 Lecture4 Intelligent Interface Agents.pdfICS2208 Lecture4 Intelligent Interface Agents.pdf
ICS2208 Lecture4 Intelligent Interface Agents.pdf
 
30-de-thi-vao-lop-10-mon-tieng-anh-co-dap-an.doc
30-de-thi-vao-lop-10-mon-tieng-anh-co-dap-an.doc30-de-thi-vao-lop-10-mon-tieng-anh-co-dap-an.doc
30-de-thi-vao-lop-10-mon-tieng-anh-co-dap-an.doc
 
LEAD6001 - Introduction to Advanced Stud
LEAD6001 - Introduction to Advanced StudLEAD6001 - Introduction to Advanced Stud
LEAD6001 - Introduction to Advanced Stud
 
Plant Tissue culture., Plasticity, Totipotency, pptx
Plant Tissue culture., Plasticity, Totipotency, pptxPlant Tissue culture., Plasticity, Totipotency, pptx
Plant Tissue culture., Plasticity, Totipotency, pptx
 
3.14.24 Gender Discrimination and Gender Inequity.pptx
3.14.24 Gender Discrimination and Gender Inequity.pptx3.14.24 Gender Discrimination and Gender Inequity.pptx
3.14.24 Gender Discrimination and Gender Inequity.pptx
 
3.12.24 Freedom Summer in Mississippi.pptx
3.12.24 Freedom Summer in Mississippi.pptx3.12.24 Freedom Summer in Mississippi.pptx
3.12.24 Freedom Summer in Mississippi.pptx
 
THYROID HORMONE.pptx by Subham Panja,Asst. Professor, Department of B.Sc MLT,...
THYROID HORMONE.pptx by Subham Panja,Asst. Professor, Department of B.Sc MLT,...THYROID HORMONE.pptx by Subham Panja,Asst. Professor, Department of B.Sc MLT,...
THYROID HORMONE.pptx by Subham Panja,Asst. Professor, Department of B.Sc MLT,...
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (FRIE...
BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (FRIE...BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (FRIE...
BÀI TẬP BỔ TRỢ TIẾNG ANH 11 THEO ĐƠN VỊ BÀI HỌC - CẢ NĂM - CÓ FILE NGHE (FRIE...
 
Arti Languages Pre Seed Send Ahead Pitchdeck 2024.pdf
Arti Languages Pre Seed Send Ahead Pitchdeck 2024.pdfArti Languages Pre Seed Send Ahead Pitchdeck 2024.pdf
Arti Languages Pre Seed Send Ahead Pitchdeck 2024.pdf
 
VIT336 – Recommender System - Unit 3.pdf
VIT336 – Recommender System - Unit 3.pdfVIT336 – Recommender System - Unit 3.pdf
VIT336 – Recommender System - Unit 3.pdf
 
EDD8524 The Future of Educational Leader
EDD8524 The Future of Educational LeaderEDD8524 The Future of Educational Leader
EDD8524 The Future of Educational Leader
 

Conversion of data types in java

  • 1. //Ques. 7 WAP to demonstrate type conversions ( int to byte, double to int, double to byte ). class conversion { public static void main(String arr[]) { byte b; inti = 257; double d = 323.142; System.out.println(" n Conversion of int to byte: "); b= (byte) i; System.out.print(" i = "+i+ " b = "+b); System.out.println("n n Conversion of double to int: "); i= (int) d; System.out.print(" d = "+d+ " i = "+i); System.out.println("n n Conversion of double to byte: "); b= (byte) d; System.out.println(" d = "+d+ " b = "+b); } }