Java Interview Questions and Answers - New Version In Hindi #12(Part-5)
1,875 views · Published 17 January 2018 · 20:08 · Indexed 10 October 2026
Channel: AndroJavaTech4U · 2018 · Science & Technology
This videos have basic java interviews questions and answers about
WHAT IS THE DIFFERENCE BETWEEN
STATIC AND NON STATIC DATAT MEMBER
IN JAVA.?
Program1-
class StudentSelected
{
String name;
static String clgname,cmpname;
int sal,age;
StudentSelected(String n,String c,String cm,int a,int s)
{
name=n;
clgname=c;
cmpname=cm;
sal=s;
age=a;
}
void viewInfo()
{
System.out.println(name+" "+clgname+" "+cmpname+" "+age+" "+sal);
}
public static void main(String ss[])
{
StudentSelected s1=new StudentSelected("ram","NIIT","TCS",23,10000);
s1.viewInfo();
StudentSelected s2=new StudentSelected("shaym","NIIT","TCS",24,20000);
s2.viewInfo();
StudentSelected s3=new StudentSelected("mohan","NIIT","TCS",25,15000);
s3.viewInfo();
}
}
Program 2-
class A
{
static int x;
A()
{
x++;
System.out.println(x);
}
public static void main(String ss[])
{
new A();
new A();
new A();
}
}
object cloning part-1
https://www.youtube.com/watch?v=oBmHMEGxKr4&t=27s
object cloning part-2
https://www.youtube.com/watch?v=B3OwNM4gKD0&t=131s
OOps ques/ans session-1 url:-
https://www.youtube.com/watch?v=xYaH5ZmKbzA&index=1&list=PLnfapp4Woqpq1VOZuvB0Gb_pe7By2cF3_
OOps ques/ans session-2 url:-
https://www.youtube.com/watch?v=T6kRMnyM0ro&index=2&list=PLnfapp4Woqpq1VOZuvB0Gb_pe7By2cF3_
OOps ques/ans session-3 url:-
https://www.youtube.com/watch?v=a4MiDc2rrxE&index=3&list=PLnfapp4Woqpq1VOZuvB0Gb_pe7By2cF3_
OOps ques/ans session-4 url:-
https://www.youtube.com/watch?v=qvLMFyEqjyk&index=4&list=PLnfapp4Woqpq1VOZuvB0Gb_pe7By2cF3_
https://www.youtube.com/watch?v=K3vYHJh0lcE&t=62s
https://www.youtube.com/watch?v=IpsXqpIQHtI&t=25s
https://www.youtube.com/watch?v=SOTjxjbCgmc&t=25s
https://www.youtube.com/watch?v=8jxCCzonDMU&t=25s
Connect on Socials:-
Facebook:- https://www.facebook.com/AndroJavaTech4U/
Twitter:- https://twitter.com/AndroJavaTech4U
Google Plus:- https://plus.google.com/u/0/+AndroJavaTech4U
LinkedIn:- https://www.linkedin.com/in/androjavatech4u/
More from this channel
-
18:08
Platform Independency Features of Java In Hindi #1
-
4:42
VMware Workstation Install With RedHat
-
5:38
JVM ( java virtual machine) architecture - tutorial
-
4:30
Java Fundamentals In Hindi #2 (Keyword In Java)
-
2:26
Working On WebLogic Server 12C In Hindi #2
-
21:59
Login and Registration Part1
-
13:55
Java Fundamentals In Hindi #4 (Variable In Java)
-
7:16
configure apache tomcat with eclipse and running first jsp