Saturday, 1 February 2020
Friday, 31 January 2020
Tuesday, 28 January 2020
Monday, 11 November 2019
Tuesday, 17 September 2019
Write a Program for exception Handling in java
Program for Exception Handling in Java using try and catch blocks
1. Open the notepad file.
2. Write the code given below in the file.
import java.util.Scanner;
class Excep
{
public static void main(String args[])
{
int div,a,b;
Scanner input= new Scanner(System.in);
System.out.println("Enter 1st Number");
a=input.nextInt();
System.out.println("Enter 2nd Number");
b=input.nextInt();
try
{
div=a/b;
1. Open the notepad file.
2. Write the code given below in the file.
import java.util.Scanner;
class Excep
{
public static void main(String args[])
{
int div,a,b;
Scanner input= new Scanner(System.in);
System.out.println("Enter 1st Number");
a=input.nextInt();
System.out.println("Enter 2nd Number");
b=input.nextInt();
try
{
div=a/b;
Monday, 16 September 2019
Socket Programming in java
Creating Chat Server in Java
1. Open two notepad files.
2. Write the codes of Server and Client in separate files.
a.) Server Code
import java.io.*;
import java.net.*;
public class MyServerCode
{DataInputStream dIS;
public MyServerCode()
{
try
{
Simple Program for creating object in JAVA.
Java Program for Object Creation
1. Open notepad file.
2. Write the code given below in notepad.
class Student
{
String name;
String age;
public static void main(String arg[])
{//Creating Object of Student class
Student obj= new Student(); // calling default constructor while creating object
System.out.println("Default Name of Object "+obj.name);
System.out.println("Default Age of Object "+obj.age);
}
}
Subscribe to:
Posts (Atom)
Dataware housing and data mining complete manual file(DWDM)
XXX UNIVERSITY Laboratory Manual DATA WAREHOUSING AND DATA MINING Practical Manual for Diploma S...
-
Learn to Make a Simple CALCULATOR in just 2 minutes with HTML without using JavaScript or CSS. ...
-
Module 1: Introduction to Indian Knowledge System (IKS) 🕉️ 1. Overview of Indian Knowledge System (IKS) Indian Knowledge System (IKS) ref...