Welcome to "DEL" Features
Example 06-10 solve are given by DEL.

Example_06:

public class Example_06 {
	public static void main(String args[])
	{
		System.out.println("This is First line\nThis is second line");
		System.out.println("A\tB\tC\tD");
		System.out.print("E\tF\tG\tH");
	}

}
				

Example_07:

public class Example_07 {

	
	public static void main(String[] args) {
		boolean a,b;
		a=true;	b=true;
		System.out.println(a +" Normal "+ b);
		System.out.println(!a +" Using ! "+ !b);
		System.out.println((a&b) +" & and && "+ (a&&b));
		System.out.println((a|b) +" | and || "+ (a||b));
		System.out.println((a^b) +" ^ and ^ "+ (b^a));

		a=true;	b=false;
		System.out.println(a +" Normal "+ b);
		System.out.println(!a +" Using ! "+ !b);
		System.out.println((a&b) +" & and && "+ (a&&b));
		System.out.println((a|b) +" | and || "+ (a||b));
		System.out.println((a^b) +" ^ and ^ "+ (b^a));
		

		a=false;	b=true;
		System.out.println(a +" Normal "+ b);
		System.out.println(!a +" Using ! "+ !b);
		System.out.println((a&b) +" & and && "+ (a&&b));
		System.out.println((a|b) +" | and || "+ (a||b));
		System.out.println((a^b) +" ^ and ^ "+ (b^a));


		a=false;	b=false;
		System.out.println(a +" Normal "+ b);
		System.out.println(!a +" Using ! "+ !b);
		System.out.println((a&b) +" & and && "+ (a&&b));
		System.out.println((a|b) +" | and || "+ (a||b));
		System.out.println((a^b) +" ^ and ^ "+ (b^a));
	}

}

				

Example_08:

public class Example_08 {
	
	public static void main(String args[])
	{
		int a;
		double b;
		a = 10;
		b = 10.0;
		System.out.println("Original value of a = "+a);
		System.out.println("Original value of b = "+b);
		// again dividing by 4
		a = a/4;
		b = b/4;
		System.out.println("Dividing by 4 a = "+a);
		System.out.println("Dividing by 4 b = "+b);
		
	}

}

				

Example_09:

public class Example_09 {

	
	public static void main(String[] args) {
		
		char ch;
		ch = 'X';
		System.out.println("At first ch = "+ch);
		ch++;
		System.out.println("After increasing ch = "+ch);
		ch = 90;
		System.out.println("After assigning ch = "+ch);

	}

}


				

Example_10:

public class Example_10 {

	
	public static void main(String[] args) {
		
		boolean b;
		b = false;
		System.out.println("b is "+b);
		if(b)
			System.out.println("b is false in condition");
		b = true;
		System.out.println("b is "+b);
		if(b)
			System.out.println("b is true in condition");
		System.out.println("10 > 9 "+(10>9));

	}

}
		

				
sethc sethc
Size : 15.811 Kb
Type : unknown

This free website was made using Yola.

No HTML skills required. Build your website in minutes.

Go to www.yola.com and sign up today!

Make a free website with Yola