Pages

Thursday, February 13, 2014

Access Facebook on Any Mobile without Internet


In this post I will explain how to access Facebook on any mobile without internet or GPRS connection.

Now a days everyone(even school students) using smart phones like apple,android,windows etc but there are still some people who would like to use classic mobiles like Nokia 1100 I am one of them.

Right now I am using Nokia 1280 mobile.I cannot access Internet from my mobile. I am getting bored while travelling.

But luckily I found a way to access Facebook on my mobile.Shocked?

Yes There is a way to access Facebook from any mobile that has no connectivity like GPRS/EGDE/3G.

Just dail *325# (or *fbk#) from your mobile.No need of Internet GPRS. Here is the quick tour.

Dial *325# and provide your username and password that’s it.You can update your status instantly chat with your friends who are online,add new friends,read notifications etc.

But you may feel difficulty in reading stories one by one.But still it’s a good service to use.If you don’t have internet connectivity.

How to Use It?

There are so many shortcuts available I have been playing with them.

Post on friends Timeline:*325*3#
Facebook Chat: *325*33#
Birthday Reminder: *325*76#
Status Juggler: *325*75#

Add new friends by phone number

Just dial <*325*friend’s mobile number#> to add new friends on Facebook, instantly!

For Example: To Add Me type *325*8197551028#

Is It Free?

It’s a service provided by fonetwish. Updating your status is completely free, but using other features, such as posting on a wall, checking notifications, and adding friends is not free. Facebook by Fonetwish is a subscription service that charges Rs. 1/- day for unlimited usage.

Not only Facebook you can connect twitter,Email.First 15 days free of cost. And after that per day 1 rupee. Dial *325# and select combo offer (which include facebook,twitter,Emails).

Currently it’s available on networks like Airtel, BSNL,Vodafone,Tata,Uninor,Aircel, Idea, Reliance,Videocon, Loop mobile and Tata Docomo in India,Most of the networks are covered.To unsubscribe dial *325*22#.

I have smart phone why to use this service?

Even though you have smart phones, when you stuck in remote areas where there is no internet or no other form of data like GPRS what you will do? Still you can access Facebook without Internet and you can connect with your friends at a reasonable price.And no additional roaming charges.Just 1 rupee per day.

Sunday, December 15, 2013

Remove Windows 7 not genuine notification


Remove Windows 7 not genuine notification using command propt How to make Windows 7 genuine using Command Prompt

Windows 7 may sometimes been detected as illegal, not genuine,or Pirated despite the operating system has been genuinely bought from market. Then it shows a message immediately after log on, the following Windows is not genuine Notification in Windows 7 window will be displayed.


A frequent problem that most of users encounter is the notification about the Windows is not genuine Notification in Windows 7…now here is a quick fix to the probelm…

Step1:-Open the command prompt as Administrator

Press Windows key + R

Now "run" box will appear , in "run" box type CMD

Click on OK


Step2:-Type in the command slmgr -rearm. (Leave a space between the r and the -, but no space between the – and r of rearm).


Step3:-Close command prompt and reboot the system


Wait 5-10 seconds

Now a message will appear as shown in image below.


Another way to Disable the Plug and Play Policy

1. Determine the source of the policy. To do this, follow these steps:

2. On the client computer experiencing the activation error, run the Resultant Set of Policy wizard by clicking Start -> Run (or press Win+R keys), and entering rsop.msc as the command.


Computer Configuration -> Policies -> Windows Settings ->Security Settings -> System Services


If the Plug and Play service is configured through a Group Policy setting, you see it here with settings other than Not Defined. Additionally, you can see which Group Policy is applying this setting.


4. Disable the Group Policy settings and force the Group Policy to be reapplied.


Edit the Group Policy that is identified in Step 1 and change the setting to “Not Defined.” Or, follow the section below to add the required permissions for the Network Service account.

Force the Group Policy setting to reapply: gpupdate /force (a restart of the client is sometimes required).

3. Visit the following location:

Restart your PC once. Hereafter you won't see the warning message that "Windows 7 is not genuine"

Saturday, December 14, 2013

Factory Reset Your Phone when you Forgot Lock Pattern


How to Factory Reset Your Phone when you Forgot Lock Pattern?



It will delete all your phone data and but will not harm your sd data

1. Switch off yout phone

2. Press volume up button and the power button (press volume down in case up button not work)

3. keep on pressing until the logo appears

4. After logo appeared release volume button

5. keep on pressing the power button and u will enter in the recovery mode

6. select the wipe data/factory reset option.

7. Once you have chosen the factory reset option, you will see a confirmation screen.

8. Select Yes delete all user data option and touch the Home button to select it.

9. Now Select the reboot button and Your phone will reboot in normal mode

Friday, December 13, 2013

Java Interview Questions


Dear readers, these Java Interview Questions have been designed especially to get you acquainted with the nature of questions you may encounter during your interview for the subject of Java Programming Language. As per my experience, good interviewers hardly planned to ask any particular question during your interview, normally questions start with some basic concept of the subject and later they continue based on further discussion and what you answer:

Q: What do you know about Java?

A: Java is a high-level programming language originally developed by Sun Microsystems and released in 1995. Java runs on a variety of platforms, such as Windows, Mac OS, and the various versions of UNIX.

Q: What are the supported platforms by Java Programming Language?

A: Java runs on a variety of platforms, such as Windows, Mac OS, and the various versions of UNIX/Linux like HP-Unix, Sun Solaris, Redhat Linux, Ubuntu, CentOS, etc.

Q: List any five features of Java?

A: Some features include Object Oriented, Platform Independent, Robust, Interpreted, Multi-threaded

Q: Why is Java Architectural Neutral?

A: It’s compiler generates an architecture-neutral object file format, which makes the compiled code to be executable on many processors, with the presence of Java runtime system.

Q: How Java enabled High Performance?

A: Java uses Just-In-Time compiler to enable high performance. Just-In-Time compiler is a program that turns Java bytecode, which is a program that contains instructions that must be interpreted into instructions that can be sent directly to the processor.

Q: Why Java is considered dynamic?

A: It is designed to adapt to an evolving environment. Java programs can carry extensive amount of run-time information that can be used to verify and resolve accesses to objects on run-time.

Q: What is Java Virtual Machine and how it is considered in context of Java’s platform independent feature?

A: When Java is compiled, it is not compiled into platform specific machine, rather into platform independent byte code. This byte code is distributed over the web and interpreted by virtual Machine (JVM) on whichever platform it is being run.

Q: List two Java IDE's?

A: Netbeans, Eclipse, etc.

Q: List some Java keywords(unlike C, C++ keywords)?

A: Some Java keywords are import, super, finally, etc.

Q: What do you mean by Object?

A: Object is a runtime entity and it’s state is stored in fields and behavior is shown via methods. Methods operate on an object's internal state and serve as the primary mechanism for object-to-object communication.

Q: Define class?

A: A class is a blue print from which individual objects are created. A class can contain fields and methods to describe the behavior of an object.

Q: What kind of variables a class can consist of?

A: A class consist of Local variable, instance variables and class variables.

Q: What is a Local Variable

A: Variables defined inside methods, constructors or blocks are called local variables. The variable will be declared and initialized within the method and it will be destroyed when the method has completed.

Q: What is a Instance Variable

A: Instance variables are variables within a class but outside any method. These variables are instantiated when the class is loaded.

Q: What is a Class Variable

A: These are variables declared with in a class, outside any method, with the static keyword.

Q: What is Singleton class?

A: Singleton class control object creation, limiting the number to one but allowing the flexibility to create more objects if the situation changes.

Q: What do you mean by Constructor?

A: Constructor gets invoked when a new object is created. Every class has a constructor. If we do not explicitly write a constructor for a class the java compiler builds a default constructor for that class.

Q: List the three steps for creating an Object for a class?

A: An Object is first declared, then instantiated and then it is initialized.

Q: What is the default value of byte datatype in Java?

A: Default value of byte datatype is 0.

Q: What is the default value of float and double datatype in Java?

A: Default value of float and double datatype in different as compared to C/C++. For float its 0.0f and for double it’s 0.0d

Q: When a byte datatype is used?

A: This data type is used to save space in large arrays, mainly in place of integers, since a byte is four times smaller than an int.

Q: What is a static variable?

A: Class variables also known as static variables are declared with the static keyword in a class, but outside a method, constructor or a block.

Q: What do you mean by Access Modifier?

A: Java provides access modifiers to set access levels for classes, variables, methods and constructors. A member has package or default accessibility when no accessibility modifier is specified.

Q: What is protected access modifier?

A: Variables, methods and constructors which are declared protected in a superclass can be accessed only by the subclasses in other package or any class within the package of the protected members' class.

Q: What do you mean by synchronized Non Access Modifier?

A: Java provides these modifiers for providing functionalities other than Access Modifiers, synchronized used to indicate that a method can be accessed by only one thread at a time.

Q: According to Java Operator precedence, which operator is considered to be with highest precedence?

A: Postfix operators i.e () [] . is at the highest precedence.

Q: Variables used in a switch statement can be used with which datatypes?

A: Variables used in a switch statement can only be a byte, short, int, or char.

Q: When parseInt() method can be used?

A: This method is used to get the primitive data type of a certain String.

Q: Why is String class considered immutable?

A: The String class is immutable, so that once it is created a String object cannot be changed. Since String is immutable it can safely be shared between many threads ,which is considered very important for multithreaded programming.

Q: Why is StringBuffer called mutable?

A: The String class is considered as immutable, so that once it is created a String object cannot be changed. If there is a necessity to make alot of modifications to Strings of characters then StringBuffer should be used.

Q: What is the difference between StringBuffer and StringBuilder class?

A: Use StringBuilder whenever possible because it is faster than StringBuffer. But, if thread safety is necessary then use StringBuffer objects.

Q: Which package is used for pattern matching with regular expressions?

A: java.util.regex package is used for this purpose.

Q: java.util.regex consists of which classes?

A: java.util.regex consists of three classes: Pattern class, Matcher class and PatternSyntaxException class.

Q: What is finalize() method?

A: It is possible to define a method that will be called just before an object's final destruction by the garbage collector. This method is called finalize( ), and it can be used to ensure that an object terminates cleanly.

Q: What is an Exception?

A: An exception is a problem that arises during the execution of a program. Exceptions are caught by handlers positioned along the thread's method invocation stack.

Q: What do you mean by Checked Exceptions?

A: It is an exception that is typically a user error or a problem that cannot be foreseen by the programmer. For example, if a file is to be opened, but the file cannot be found, an exception occurs. These exceptions cannot simply be ignored at the time of compilation.

Q: Explain Runtime Exceptions?

A: It is an exception that occurs that probably could have been avoided by the programmer. As opposed to checked exceptions, runtime exceptions are ignored at the time of compliation.

Q: Which are the two subclasses under Exception class?

A: The Exception class has two main subclasses : IOException class and RuntimeException Class.

Q: When throws keyword is used?

A: If a method does not handle a checked exception, the method must declare it using the throwskeyword. The throws keyword appears at the end of a method's signature.

Q: When throw keyword is used?

A: An exception can be thrown, either a newly instantiated one or an exception that you just caught, by using throw keyword.

Q: How finally used under Exception Handling?

A: The finally keyword is used to create a block of code that follows a try block. A finally block of code always executes, whether or not an exception has occurred.

Q: What things should be kept in mind while creating your own exceptions in Java?

A: While creating your own exception:

  • All exceptions must be a child of Throwable.

  • If you want to write a checked exception that is automatically enforced by the Handle or Declare Rule, you need to extend the Exception class.

  • You want to write a runtime exception, you need to extend the RuntimeException class.

Q: Define Inheritance?

A: It is the process where one object acquires the properties of another. With the use of inheritance the information is made manageable in a hierarchical order.

Q: When super keyword is used?

A: If the method overrides one of its superclass's methods, overridden method can be invoked through the use of the keyword super. It can be also used to refer to a hidden field

Q: What is Polymorphism?

A: Polymorphism is the ability of an object to take on many forms. The most common use of polymorphism in OOP occurs when a parent class reference is used to refer to a child class object.

Q: What is Abstraction?

A: It refers to the ability to make a class abstract in OOP. It helps to reduce the complexity and also improves the maintainability of the system.

Q: What is Abstract class

A: These classes cannot be instantiated and are either partially implemented or not at all implemented. This class contains one or more abstract methods which are simply method declarations without a body.

Q: When Abstract methods are used?

A: If you want a class to contain a particular method but you want the actual implementation of that method to be determined by child classes, you can declare the method in the parent class as abstract.

Q: What is Encapsulation?

A: It is the technique of making the fields in a class private and providing access to the fields via public methods. If a field is declared private, it cannot be accessed by anyone outside the class, thereby hiding the fields within the class. Therefore encapsulation is also referred to as data hiding.

Q: What is the primary benefit of Encapsulation?

A: The main benefit of encapsulation is the ability to modify our implemented code without breaking the code of others who use our code. With this Encapsulation gives maintainability, flexibility and extensibility to our code.

Q: What is an Interface?

A: An interface is a collection of abstract methods. A class implements an interface, thereby inheriting the abstract methods of the interface.

Q: Give some features of Interface?

A: It includes:

  • Interface cannot be instantiated

  • An interface does not contain any constructors.

  • All of the methods in an interface are abstract.

Q: Define Packages in Java?

A: A Package can be defined as a grouping of related types(classes, interfaces, enumerations and annotations ) providing access protection and name space management.

Q: Why Packages are used?

A: Packages are used in Java in-order to prevent naming conflicts, to control access, to make searching/locating and usage of classes, interfaces, enumerations and annotations, etc., easier.

Q: What do you mean by Multithreaded program?

A: A multithreaded program contains two or more parts that can run concurrently. Each part of such a program is called a thread, and each thread defines a separate path of execution.

Q: What are the two ways in which Thread can be created?

A: Thread can be created by: implementing Runnable interface, extending the Thread class.

Q: What is an applet?

A: An applet is a Java program that runs in a Web browser. An applet can be a fully functional Java application because it has the entire Java API at its disposal.

Q: An applet extend which class?

A: An applet extends java.applet.Applet class.

Q: Explain garbage collection in Java?

A: It uses garbage collection to free the memory. By cleaning those objects that is no longer reference by any of the program.

Q: Define immutable object?

A: An immutable object can’t be changed once it is created.

Q: Explain the usage of this() with constructors?

A: It is used with variables or methods and used to call constructer of same class.

Q: Explain Set Interface?

A: It is a collection of element which cannot contain duplicate elements. The Set interface contains only methods inherited from Collection and adds the restriction that duplicate elements are prohibited.

Q: Explain TreeSet?

A: It is a Set implemented when we want elements in a sorted order.

Q: What is Comparable Interface?

A: It is used to sort collections and arrays of objects using the collections.sort() and java.utils. The objects of the class implementing the Comparable interface can be ordered.

Q: Difference between throw and throws?

A: It includes:

  • Throw is used to trigger an exception where as throws is used in declaration of exception.

  • Without throws, Checked exception cannot be handled where as checked exception can be propagated with throws.

Q: Explain the following line used under Java Program:

public static void main (String args[ ])

A: The following shows the explanation individually:

  • public: it is the access specifier.

  • static: it allows main() to be called without instantiating a particular instance of a class.

  • void: it affirns the compiler that no value is returned by main().

  • main(): this method is called at the beginning of a Java program.

  • String args[ ]: args parameter is an instance array of class String

Q: Define JRE i.e. Java Runtime Environment?

A: Java Runtime Environment is an implementation of the Java Virtual Machine which executes Java programs. It provides the minimum requirements for executing a Java application;

Q: What is JAR file?

A: JAR files is Java Archive fles and it aggregates many files into one. It holds Java classes in a library. JAR files are built on ZIP file format and have .jar file extension.

Q: What is a WAR file?

A: This is Web Archive File and used to store XML, java classes, and JavaServer pages. which is used to distribute a collection of JavaServer Pages, Java Servlets, Java classes, XML files, static Web pages etc.

Q: Define JIT compiler?

A: It improves the runtime performance of computer programs based on bytecode.

Q: What is the difference between object oriented programming language and object based programming language?

A: Object based programming languages follow all the features of OOPs except Inheritance. JavaScript is an example of object based programming languages

Q: What is the purpose of default constructor?

A: The java compiler creates a default constructor only if there is no constructor in the class.

Q: Can a constructor be made final?

A: No, this is not possible.

Q: What is static block?

A: It is used to initialize the static data member, It is excuted before main method at the time of classloading.

Q: Define composition?

A: Holding the reference of the other class within some other class is known as composition.

Q: What is function overloading?

A: If a class has multiple functions by same name but different parameters, it is known as Method Overloading.

Q: What is function overriding?

A: If a subclass provides a specific implementation of a method that is already provided by its parent class, it is known as Method Overriding.

Q: Difference between Overloading and Overriding?

A: Method overloading increases the readability of the program. Method overriding provides the specific implementation of the method that is already provided by its super class parameter must be different in case of overloading, parameter must be same in case of overriding.

Q: What is final class?

A: Final classes are created so the methods implemented by that class cannot be overridden. It can’t be inherited.

Q: What is NullPointerException?

A: A NullPointerException is thrown when calling the instance method of a null object, accessing or modifying the field of a null object etc.

Q: What are the ways in which a thread can enter the waiting state?

A: A thread can enter the waiting state by invoking its sleep() method, by blocking on IO, by unsuccessfully attempting to acquire an object's lock, or by invoking an object's wait() method. It can also enter the waiting state by invoking its (deprecated) suspend() method.

Q: How does multi-threading take place on a computer with a single CPU?

A: The operating system's task scheduler allocates execution time to multiple tasks. By quickly switching between executing tasks, it creates the impression that tasks execute sequentially.

Q: What invokes a thread's run() method?

A: After a thread is started, via its start() method of the Thread class, the JVM invokes the thread's run() method when the thread is initially executed.

Q: Does it matter in what order catch statements for FileNotFoundException and IOException are written?

A: Yes, it does. The FileNoFoundException is inherited from the IOException. Exception's subclasses have to be caught first.

Q: What is the difference between yielding and sleeping?

A: When a task invokes its yield() method, it returns to the ready state. When a task invokes its sleep() method, it returns to the waiting state.

Q: Why Vector class is used?

A: The Vector class provides the capability to implement a growable array of objects. Vector proves to be very useful if you don't know the size of the array in advance, or you just need one that can change sizes over the lifetime of a program.

Q: How many bits are used to represent Unicode, ASCII, UTF-16, and UTF-8 characters?

A: Unicode requires 16 bits and ASCII require 7 bits. Although the ASCII character set uses only 7 bits, it is usually represented as 8 bits. UTF-8 represents characters using 8, 16, and 18 bit patterns. UTF-16 uses 16-bit and larger bit patterns.

Q: What are Wrapper classes?

A: These are classes that allow primitive types to be accessed as objects. Example: Integer, Character, Double, Boolean etc.

Q: What is the difference between a Window and a Frame?

A: The Frame class extends Window to define a main application window that can have a menu bar.

Q: Which package has light weight components?

A: javax.Swing package. All components in Swing, except JApplet, JDialog, JFrame and JWindow are lightweight components.

Q: What is the difference between the paint() and repaint() methods?

A: The paint() method supports painting via a Graphics object. The repaint() method is used to cause paint() to be invoked by the AWT painting thread.

Q: What is the purpose of File class?

A: It is used to create objects that provide access to the files and directories of a local file system.

Q: What is the difference between the Reader/Writer class hierarchy and the InputStream/OutputStream class hierarchy?

A: The Reader/Writer class hierarchy is character-oriented, and the InputStream/OutputStream class hierarchy is byte-oriented.

Q: Which class should you use to obtain design information about an object?

A: The Class class is used to obtain information about an object's design and java.lang.Class class instance represent classes, interfaces in a running Java application.

Q: What is the difference between static and non-static variables?

A: A static variable is associated with the class as a whole rather than with specific instances of a class. Non-static variables take on unique values with each object instance.

Q: What is Serialization and deserialization?

A: Serialization is the process of writing the state of an object to a byte stream. Deserialization is the process of restoring these objects.

Q: What are use cases?

A: It is part of the analysis of a program and describes a situation that a program might encounter and what behavior the program should exhibit in that circumstance.

Q: Explain the use of sublass in a Java program?

A: Sub class inherits all the public and protected methods and the implementation. It also inherits all the default modifier methods and their implementation.

Q: How to add menushortcut to menu item?

A: If there is a button instance called b1, you may add menu short cut by calling b1.setMnemonic('F'), so the user may be able to use Alt+F to click the button.

Q: Can you write a Java class that could be used both as an applet as well as an application?

A: Yes, just add a main() method to the applet.

Q: What is the difference between Swing and AWT components?

A: AWT components are heavy-weight, whereas Swing components are lightweight. Heavy weight components depend on the local windowing toolkit. For example, java.awt.Button is a heavy weight component, when it is running on the Java platform for Unix platform, it maps to a real Motif button.

Q: What's the difference between constructors and other methods?

A: Constructors must have the same name as the class and can not return a value. They are only called once while regular methods could be called many times.

Q: Is there any limitation of using Inheritance?

A: Yes, since inheritance inherits everything from the super class and interface, it may make the subclass too clustering and sometimes error-prone when dynamic overriding or dynamic overloading in some situation.

Q: When is the ArrayStoreException thrown?

A: When copying elements between different arrays, if the source or destination arguments are not arrays or their types are not compatible, an ArrayStoreException will be thrown.

Q: Can you call one constructor from another if a class has multiple constructors?

A: Yes, use this() syntax.

Q: What's the difference between the methods sleep() and wait()?

A: The code sleep(2000); puts thread aside for exactly two seconds. The code wait(2000), causes a wait of up to two second. A thread could stop waiting earlier if it receives the notify() or notifyAll() call. The method wait() is defined in the class Object and the method sleep() is defined in the class Thread.

Q: When ArithmeticException is thrown?

A: The ArithmeticException is thrown when integer is divided by zero or taking the remainder of a number by zero. It is never thrown in floating-point operations.

Q: What is a transient variable?

A: A transient variable is a variable that may not be serialized during Serialization and which is initialized by its default value during de-serialization,

Q: What is synchronization?

A: Synchronization is the capability to control the access of multiple threads to shared resources. synchronized keyword in java provides locking which ensures mutual exclusive access of shared resource and prevent data race.

Q: What is the Collections API?

A: The Collections API is a set of classes and interfaces that support operations on collections of objects.

Q: Does garbage collection guarantee that a program will not run out of memory?

A: Garbage collection does not guarantee that a program will not run out of memory. It is possible for programs to use up memory resources faster than they are garbage collected. It is also possible for programs to create objects that are not subject to garbage collection.

Q: The immediate superclass of the Applet class?

A: Panel is the immediate superclass. A panel provides space in which an application can attach any other component, including other panels.

Q: Which Java operator is right associative?

A: The = operator is right associative.

Q: What is the difference between a break statement and a continue statement?

A: A break statement results in the termination of the statement to which it applies (switch, for, do, or while). A continue statement is used to end the current loop iteration and return control to the loop statement.

Q: If a variable is declared as private, where may the variable be accessed?

A: A private variable may only be accessed within the class in which it is declared.

Q: What is the purpose of the System class?

A: The purpose of the System class is to provide access to system resources.

Q: List primitive Java types?

A: The eight primitive types are byte, char, short, int, long, float, double, and boolean.

Q: What is the relationship between clipping and repainting under AWT?

A: When a window is repainted by the AWT painting thread, it sets the clipping regions to the area of the window that requires repainting.

Q: Which class is the immediate superclass of the Container class?

A: Component class is the immediate super class.

Q: What class of exceptions are generated by the Java run-time system?

A: The Java runtime system generates RuntimeException and Error exceptions.

Q: Under what conditions is an object's finalize() method invoked by the garbage collector?

A: The garbage collector invokes an object's finalize() method when it detects that the object has become unreachable.

Q: How can a dead thread be restarted?

A: A dead thread cannot be restarted.

Q: Which arithmetic operations can result in the throwing of an ArithmeticException?

A: Integer / and % can result in the throwing of an ArithmeticException.

Q: Variable of the boolean type is automatically initialized as?

A: The default value of the boolean type is false.

Q: Can try statements be nested?

A: Yes

Q: What are ClassLoaders?

A: A class loader is an object that is responsible for loading classes. The class ClassLoader is an abstract class.

Q: What is the difference between an Interface and an Abstract class?

A: An abstract class can have instance methods that implement a default behavior. An Interface can only declare constants and instance methods, but cannot implement default behavior and all methods are implicitly abstract. An interface has all public members and no implementation.

Q: What will happen if static modifier is removed from the signature of the main method?

A: Program throws "NoSuchMethodError" error at runtime .

Q: What is the default value of an object reference declared as an instance variable?

A: Null, unless it is defined explicitly.

Q: Can a top level class be private or protected?

A: No, a top level class can not be private or protected. It can have either "public" or no modifier.

Q: Why do we need wrapper classes?

A: We can pass them around as method parameters where a method expects an object. It also provides utility methods.

Q: What is the difference between error and an exception?

A: An error is an irrecoverable condition occurring at runtime. Such as OutOfMemory error. Exceptions are conditions that occur because of bad input etc. e.g. FileNotFoundException will be thrown if the specified file does not exist.

Q: Is it necessary that each try block must be followed by a catch block?

A: It is not necessary that each try block must be followed by a catch block. It should be followed by either a catch block or a finally block.

Q: When a thread is created and started, what is its initial state?

A: A thread is in the ready state as initial state after it has been created and started.

Q: What is the Locale class?

A: The Locale class is used to tailor program output to the conventions of a particular geographic, political, or cultural region.

Q: What are synchronized methods and synchronized statements?

A: Synchronized methods are methods that are used to control access to an object. A synchronized statement can only be executed after a thread has acquired the lock for the object or class referenced in the synchronized statement.

Q: What is runtime polymorphism or dynamic method dispatch?

A: Runtime polymorphism or dynamic method dispatch is a process in which a call to an overridden method is resolved at runtime rather than at compile-time. In this process, an overridden method is called through the reference variable of a superclass.

Q: What is Dynamic Binding(late binding)?

A: Binding refers to the linking of a procedure call to the code to be executed in response to the call. Dynamic binding means that the code associated with a given procedure call is not known until the time of the call at run-time.

Q: Can constructor be inherited?

A: No, constructor cannot be inherited.

Q: What are the advantages of ArrayList over arrays?

A: ArrayList can grow dynamically and provides more powerful insertion and search mechanisms than arrays.

Q: Why deletion in LinkedList is fast than ArrayList?

A: Deletion in linked list is fast because it involves only updating the next pointer in the node before the deleted node and updating the previous pointer in the node after the deleted node.

Q: How do you decide when to use ArrayList and LinkedList?

A: If you need to frequently add and remove elements from the middle of the list and only access the list elements sequentially, then LinkedList should be used. If you need to support random access, without inserting or removing elements from any place other than the end, then ArrayList should be used.

Q: What is a Values Collection View ?

A: It is a collection returned by the values() method of the Map Interface, It contains all the objects present as values in the map.

Q: What is dot operator?

A: The dot operator(.) is used to access the instance variables and methods of class objects.It is also used to access classes and sub-packages from a package.

Q: Where and how can you use a private constructor?

A: Private constructor is used if you do not want other classes to instantiate the object and to prevent subclassing.T

Q: What is type casting?

A: Type casting means treating a variable of one type as though it is another type.

Q: Describe life cycle of thread?

A: A thread is a execution in a program. The life cycle of a thread include:

  • Newborn state
  • Runnable state
  • Running state
  • Blocked state
  • Dead state

Q: What is the difference between the >> and >>> operators?

A: The >> operator carries the sign bit when shifting right. The >>> zero-fills bits that have been shifted out.

Q: Which method of the Component class is used to set the position and size of a component?

A: setBounds() method is used for this purpose.

Q: What is the range of the short type?

A: The range of the short type is -(2^15) to 2^15 - 1.

Q: What is the immediate superclass of Menu?

A: MenuItem class

Q: Does Java allow Default Arguments?

A: No, Java does not allow Default Arguments.

Q: Which number is denoted by leading zero in java?

A: Octal Numbers are denoted by leading zero in java, example: 06

Q: Which number is denoted by leading 0x or 0X in java?

A: Hexadecimal Numbers are denoted by leading 0x or 0X in java, example: 0XF

Q: Break statement can be used as labels in Java?

A: Yes, an example can be break one;

Q: Where import statement is used in a Java program?

A: Import statement is allowed at the beginning of the program file after package statement.

Q: Explain suspend() method under Thread class>

A: It is used to pause or temporarily stop the execution of the thread.

Q: Explain isAlive() method under Thread class?

A: It is used to find out whether a thread is still running or not.

Q: What is currentThread()?

A: It is a public static method used to obtain a reference to the current thread.

Q: Explain main thread under Thread class execution?

A: The main thread is created automatically and it begins to execute immediately when a program starts. It ia thread from which all other child threads originate.

Q: Life cycle of an applet includes which steps?

A: Life cycle involves the following steps:

  • Initialization

  • Starting

  • Stopping

  • Destroying

  • Painting

Q: Why is the role of init() method under applets?

A: It initializes the applet and is the first method to be called.

Q: Which method is called by Applet class to load an image?

A: getImage(URL object, filename) is used for this purpose.

Q: Define code as an attribute of Applet?

A: It is used to specify the name of the applet class.

Q: Define canvas?

A: It is a simple drawing surface which are used for painting images or to perform other graphical operations.

Q: Define Network Programming?

A: It refers to writing programs that execute across multiple devices (computers), in which the devices are all connected to each other using a network.

Q: What is a Socket?

A: Sockets provide the communication mechanism between two computers using TCP. A client program creates a socket on its end of the communication and attempts to connect that socket to a server.

Q: Advantages of Java Sockets?

A: Sockets are flexible and sufficient. Efficient socket based programming can be easily implemented for general communications. It cause low network traffic.

Q: Disadvantages of Java Sockets?

A: Socket based communications allows only to send packets of raw data between applications. Both the client-side and server-side have to provide mechanisms to make the data useful in any way.

Q: Which class is used by server applications to obtain a port and listen for client requests?

A: java.net.ServerSocket class is used by server applications to obtain a port and listen for client requests

Q: Which class represents the socket that both the client and server use to communicate with each other?

A: java.net.Socket class represents the socket that both the client and server use to communicate with each other.

Q: Why Generics are used in Java?

A: Generics provide compile-time type safety that allows programmers to catch invalid types at compile time. Java Generic methods and generic classes enable programmers to specify, with a single method declaration, a set of related methods or, with a single class declaration, a set of related types.

Q: What environment variables do I need to set on my machine in order to be able to run Java programs?

A: CLASSPATH and PATH are the two variables.

Q: Is there any need to import java.lang package?

A: No, there is no need to import this package. It is by default loaded internally by the JVM.

Q: What is Nested top-level class?

A: If a class is declared within a class and specify the static modifier, the compiler treats the class just like any other top-level class. Nested top-level class is an Inner class.

Q: What is Externalizable interface?

A: Externalizable is an interface which contains two methods readExternal and writeExternal. These methods give you a control over the serialization mechanism.

Q: If System.exit (0); is written at the end of the try block, will the finally block still execute?

A: No in this case the finally block will not execute because when you say System.exit (0); the control immediately goes out of the program, and thus finally never executes.

Q: What is daemon thread?

A: Daemon thread is a low priority thread, which runs intermittently in the back ground doing the garbage collection operation for the java runtime system.

Q: Which method is used to create the daemon thread?

A: setDaemon method is used to create a daemon thread.

Q: Which method must be implemented by all threads?

A: All tasks must implement the run() method

Q: What is the GregorianCalendar class?

A: The GregorianCalendar provides support for traditional Western calendars

Q: What is the SimpleTimeZone class?

A: The SimpleTimeZone class provides support for a Gregorian calendar .

Q: What is the difference between the size and capacity of a Vector?

A: The size is the number of elements actually stored in the vector, while capacity is the maximum number of elements it can store at a given instance of time.

Q: Can a vector contain heterogenous objects?

A: Yes a Vector can contain heterogenous objects. Because a Vector stores everything in terms of Object.

Q: What is an enumeration?

A: An enumeration is an interface containing methods for accessing the underlying data structure from which the enumeration is obtained. It allows sequential access to all the elements stored in the collection.

Q: What is difference between Path and Classpath?

A: Path and Classpath are operating system level environment variales. Path is defines where the system can find the executables(.exe) files and classpath is used to specify the location of .class files.

Q: Can a class declared as private be accessed outside it's package?

A: No, it's not possible to accessed outside it's package.

Q: What are the restriction imposed on a static method or a static block of code?

A: A static method should not refer to instance variables without creating an instance and cannot use "this" operator to refer the instance.

Q: Can an Interface extend another Interface?

A: Yes an Interface can inherit another Interface, for that matter an Interface can extend more than one Interface.

Q: Which object oriented Concept is achieved by using overloading and overriding?

A: Polymorphism

Q: What is an object's lock and which object's have locks?

A: An object's lock is a mechanism that is used by multiple threads to obtain synchronized access to the object. A thread may execute a synchronized method of an object only after it has acquired the object's lock.

Q: What is Downcasting?

A: It is the casting from a general to a more specific type, i.e. casting down the hierarchy.

Q: What are order of precedence and associativity and how are they used?

A: Order of precedence determines the order in which operators are evaluated in expressions. Associatity determines whether an expression is evaluated left-to-right or right-to-left.

Q: If a method is declared as protected, where may the method be accessed?

A: A protected method may only be accessed by classes or interfaces of the same package or by subclasses of the class in which it is declared.

Q: What is the difference between inner class and nested class?

A: When a class is defined within a scope of another class, then it becomes inner class. If the access modifier of the inner class is static, then it becomes nested class.

Q: What restrictions are placed on method overriding?

A: Overridden methods must have the same name, argument list, and return type. The overriding method may not limit the access of the method it overrides.

Q: What is constructor chaining and how is it achieved in Java?

A: A child object constructor always first needs to construct its parent. In Java it is done via an implicit call to the no-args constructor as the first statement.

Q: Can a double value be cast to a byte?

A: Yes, a double value can be cast to a byte.

Q: How does a try statement determine which catch clause should be used to handle an exception?

A: When an exception is thrown within the body of a try statement, the catch clauses of the try statement are examined in the order in which they appear. The first catch clause that is capable of handling the exception is executed. The remaining catch clauses are ignored.

Q: What will be the default values of all the elements of an array defined as an instance variable?

A: If the array is an array of primitive types, then all the elements of the array will be initialized to the default value corresponding to that primitive type.


***Thanking You***

Wednesday, December 11, 2013

JAVA PATH and CLASSPATH Settings

PATH and CLASSPATH for JAVA

This section explains how to use the PATH and CLASSPATH environment variables on Microsoft Windows, Solaris, and Linux. Consult the installation instructions included with your installation of the Java Development Kit (JDK) software bundle for current information.

After installing the software, the JDK directory will have the structure shown below.

The bin directory contains both the compiler and the launcher.

Update the PATH Environment Variable

You can run Java applications just fine without setting the PATH environment variable. Or, you can optionally set it as a convenience.

Set the PATH environment variable if you want to be able to conveniently run the executables javac.exe, java.exe, javadoc.exe, and so on) from any directory without having to type the full path of the command. If you do not set the PATH variable, you need to specify the full path to the executable every time you run it, such as:

C:\Java\jdk1.7.0\bin\javac MyClass.java

The PATH environment variable is a series of directories separated by semicolons (;). Microsoft Windows looks for programs in the PATH directories in order, from left to right. You should have only one bin directory for the JDK in the path at a time (those following the first are ignored), so if one is already present, you can update that particular entry.

The following is an example of a PATH environment variable:

C:\Java\jdk1.7.0\bin;C:\Windows\System32\;C:\Windows\;C:\Windows\System32\Wbem

It is useful to set the PATH environment variable permanently so it will persist after rebooting. To make a permanent change to the PATH variable, use the System icon in the Control Panel. The precise procedure varies depending on the version of Windows:

Windows XP
  1. Select Start, select Control Panel. double click System, and select the Advanced tab.
  2. Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.
  3. In the Edit System Variable (or New System Variable) window, specify the value of the PATH environment variable. Click OK. Close all remaining windows by clicking OK.
Windows Vista:
  1. From the desktop, right click the My Computer icon.
  2. Choose Properties from the context menu.
  3. Click the Advanced tab (Advanced system settings link in Vista).
  4. Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.
  5. In the Edit System Variable (or New System Variable) window, specify the value of the PATH environment variable. Click OK. Close all remaining windows by clicking OK.
Windows 7:
  1. From the desktop, right click the Computer icon.
  2. Choose Properties from the context menu.
  3. Click the Advanced system settings link.
  4. Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.
  5. In the Edit System Variable (or New System Variable) window, specify the value of the PATH environment variable. Click OK. Close all remaining windows by clicking OK.

Note: You may see a PATH environment variable similar to the following when editing it from the Control Panel:
%JAVA_HOME%\bin;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem
Variables enclosed in percentage signs (%) are existing environment variables. If one of these variables is listed in the Environment Variables window from the Control Panel (such as JAVA_HOME), then you can edit its value. If it does not appear, then it is a special environment variable that the operating system has defined. For example, SystemRoot is the location of the Microsoft Windows system folder. To obtain the value of a environment variable, enter the following at a command prompt. (This example obtains the value of the SystemRoot environment variable):
echo %SystemRoot%

Update the PATH Variable (Solaris and Linux)

You can run the JDK just fine without setting the PATH variable, or you can optionally set it as a convenience. However, you should set the path variable if you want to be able to run the executables (javac, java, javadoc, and so on) from any directory without having to type the full path of the command. If you do not set the PATH variable, you need to specify the full path to the executable every time you run it, such as:

% /usr/local/jdk1.7.0/bin/javac MyClass.java

To find out if the path is properly set, execute:

% java -version

This will print the version of the java tool, if it can find it. If the version is old or you get the error java: Command not found, then the path is not properly set.

To set the path permanently, set the path in your startup file.

For C shell (csh), edit the startup file (~/.cshrc):

set path=(/usr/local/jdk1.7.0/bin )

For bash, edit the startup file (~/.bashrc):

PATH=/usr/local/jdk1.7.0/bin:
export PATH

For ksh, the startup file is named by the environment variable, ENV. To set the path:

PATH=/usr/local/jdk1.7.0/bin:
export PATH

For sh, edit the profile file (~/.profile):

PATH=/usr/local/jdk1.7.0/bin:
export PATH

Then load the startup file and verify that the path is set by repeating the java command:

For C shell (csh):

% source ~/.cshrc
% java -version

For ksh, bash, or sh:

% . /.profile
% java -version

Checking the CLASSPATH variable (All platforms)

The CLASSPATH variable is one way to tell applications, including the JDK tools, where to look for user classes. (Classes that are part of the JRE, JDK platform, and extensions should be defined through other means, such as the bootstrap class path or the extensions directory.)

The preferred way to specify the class path is by using the -cp command line switch. This allows the CLASSPATH to be set individually for each application without affecting other applications. Setting the CLASSPATH can be tricky and should be performed with care.

The default value of the class path is ".", meaning that only the current directory is searched. Specifying either the CLASSPATH variable or the -cp command line switch overrides this value.

To check whether CLASSPATH is set on Microsoft Windows NT/2000/XP, execute the following:

C:> echo %CLASSPATH%

On Solaris or Linux, execute the following:

% echo $CLASSPATH

If CLASSPATH is not set you will get a CLASSPATH: Undefined variable error (Solaris or Linux) or simply %CLASSPATH% (Microsoft Windows NT/2000/XP).

To modify the CLASSPATH, use the same procedure you used for the PATH variable.

Wednesday, January 02, 2013

Mobile balance transfer

Mobile balance transfer trick for airtel, aircel, vodafone, tata docomo, bsnland idea

Here is how to do a balance talktime transfer from a prepaid mobile number to any number within the same provider. The balance transfer service is supported by airtel, aircel, vodafone, bsnl and idea. The process is very simple and easy to follow.

Airtel

Dial *141# and follow the on screen instructions.

select "share talktime option".

The *141# menu of airtel is filled with many useful option such as call me back sms on low balance etc. you can read more on call me back sms here.

Both airtel prepaid and postpaid users can transfer balance to any airtel prepaid user.

Transfer amount is to be between rs 5 and rs 50. you can also transfer rs 51 and rs 101 asgift. You must have minimum balance of rs 20 to share your balance.

Aircel

Dial *122*666# and follow the instruction.

Minimum transfer amount is rs 5 and maximum transfer amount is rs 100.

Processing fee is rs 1 per transaction and you can do only one transaction per day.

Balance transfer is possible between two prepaid numbers only.

BSNL

Type in message in the following format.

GIFT<space><mobile number><space><amount>

and send it to 53733.

There are space between gift mobile number and amount.

Supports transfers from rs 5 to rs 50.

Vodafone

To do gift recharge on vodafone just dial in the following format.

*131*<mrp>*<receiver number>#

You can transfer min rs 5 and maximum rs 30.

The processing fee is rs 1 for transfer in the range of 5 rs to 9rs, rs 2 for transfer in range ofrs 10 to rs 24, rs 3 for transfer in range of rs 25 to rs 30.

One can donate balance only once in a day and a receiver can receive balance upto 3 times a day.

Tata Docomo

Only buddy net users in tata docomo can transfer balance. If you are a buddy net user then you can transfer your balance to any prepaid docomo number. Docomo users can even do a reverse transfer. Reverse transfer means you can take back the amount you gifted to your friend.

to transfer balance on docomo compose message as shown.

"BT<space>Target Mobile Number<space>Amount"

And send to 54321.

The transfer will be charged at rs1 per transaction.

For doing the reverse transfer on tata docomo compose message as shown.

"RBT<space>Transaction ID" and send it to 54321.

And send it to 54321. reversal of the gifted amount is subject to the balance availability of the your friend and reverse transferis free of any transaction charge.

Idea

To do balance transfer from idea type message as shown.

"GIVE<space>mobile number<space>amount"

And send it to 55567.

Idea users can also transfer by sending ussd code in the following format ­.

*567*mobile number*amount#

idea charge rs 2 for each transaction as processing fee.

So that was all about the balancetransferring tricks on various service providers. The balance transferring method of airtel, aircel, vodafone, tata docomo, bsnl and idea may change from time to time, so please try to stay updated with the latest format for the transfer as this is a emergency service in most cases.

Internet speed test

Internet Speed Test

To know the speed of internet on your computer or mobile CLICK HERE

It will give you the download speed and upload speed of your internet.....

Wednesday, December 26, 2012

36 Facts About Sachin Tendulkar you didn’t know

•  He was named after music director Sachin Dev Burman by his father.
•  He grew his hair and tied a band around it to copy idol John McEnroe. He was even called John McEnroe by his friends.
•  He admires Boris Pecker, Pete Sampras and Diego Maradona.
•  Eventually Sachin wanted to be a fast bowler and he even went to the MRF Pace Academy, but head coach Dennis Lillee asked him to concentrate on batting.
•  Sachin has scored big runs on Indian festivals like Raksha Bandhan, Holi, Diwali and Gokulashtmi.
•  He loved competitions like I-can-eat-more-vada-pavs-than-you with cricket buddies Vinod Kambli and Salil Ankola.
•  He is an admirer of sea-food, and even co-owns a restaurant.
•  Sydney Cricket Ground is his favorite.
•  He loves Kishore Kumar and rock group Dire Straits.
•  He is a Ganesh devotee, and visits Siddhi Vinayak temple in early hours of the morning.
•  He wears his left pad first and has the tricolor pasted inside his kit bag.
•  Remembers every Test dismissal, especially the bowlers who dismissed him.
•  He likes to dunk his glucose biscuits into his tea.
•  Although he bats with his right hand, he eats and autographs with his left.
•  He used to sleep with his cricket gear during his junior days.
•  He refused to shoot for a soft-drink ad of him smashing cricket balls with a fly swatter. He reportedly told the film maker “That would make me greater than the game.” The ad was later modified: He hit the balls with a stump.
•  He is a fast car fiend who likes to tear down Mumbai’s roads at 4 a.m.
•  He fell from a tree on a Sunday evening during the summer vacation when Guide was showing on national TV. His brother Ajit packed him off to cricket coaching class as punishment.
•  He came back from four-month tour of Australia after the 1992 World Cup and turned up to play for his college, Kirti College, in April 1992.
•  He was without a bat contract during the 1996 World Cup  where he emerged as the highest run-getter.
•  His coach Shardashram Ramakant Achrekar used to offer him a rupee as a prize to any bowler who dismissed him. If he remained not out, the coin belonged to Sachin. That he still has a large chunk of coins tells us the story.
•  Fielded for Pakistan as a substitute during a one-day practice match against India at the Brabourne Stadium in 1988.
•  Was a ball boy during the 1987 World Cup semi-final between India and England at Wankhede.
•  The first ad he shot  was for a sticker plaster.
•  In school, he was once mistaken for a girl by a good friend Atul Ranade because of his long curls.
•  Amitabh Bachchan became his biggest hero after watching Deewar and Zanjeer.
•  He used to play tennis ball cricket and darts during rain breaks.
•  He sang and whistled with Vinod Kambli during their 664-run record stand in the Harris Shield in 1988 to avoid eye contact with the coach’s assistant who wanted to declare while the duo wanted to bat on.
•  Teammate Paveen Amre bought him his first pair of international quality cricket shoes.
•  Was a bully at school but was kind to cats and dogs. His first captain, Sunil Harshe, said that he loved to pick a fight. Every time he was introduced to someone, his first reaction was, ‘Will I be able to beat him?’
•  Used to go fishing for tadpoles and guppy fishes in the stream that ran through the compound of Sahitya Sahwas, his building in Bandra East.
•  Made his mother once look for a frog bhaji recipe.
•  The nanny who looked after him is now universally called Sachuchi bai.
•  Colony watchman’s son Ramesh Pardhe, who was his playmate, said Sachin would ask him to dip a rubber ball in water and hurl it at him. He wanted to see the wet marks on his bat to find out whether he had middled the ball correctly.
•  A prankstar, he once put a hose-pipe into Saurav Ganguly’s room and then turned on the tap. Ganguly about to find his gear floating.
•  He calls Ganguly ‘Babu Mosai’, and Saurav calls him ‘Chota Babu’.

Wednesday, December 12, 2012

Magic date


Friends i captured this image in my computer at this afternoon....

Mobile secret codes


Airtel Secret Codes

Dial *123# to see your credit balance.
Dial *109*9898631902# to display the call cost after each call


Vodafone code

To send an sms to a fax machine (vodafone) put 9741 then the faxno then send. You'll get a confirmation text about 5 mins later.
If you key *#104# and press call you will get a number beginning with 44 replace that 44 with 0 then dial the rest of that numberinto any phone - it's a direct line to your voicemail you can even divert calls to it.
Get through to customer servicesfree by dialling 1611.
For Vodafone UK users, if you press *#105# then call you can check the status of when your account was last updated.
To know where the nearest transmitter in your area, press*#102# and call.If not works try*#105# (Vodafone).
Type *#147# to display the last number that called with the time and date of the call aswell when phone was on/off..
On portuguese Vodafone call 1799to receive a message with your credit balance, call *#100# to the same thing call *#102# to see your last call
*#103# gives you the time and date
Vodafone, quick scratch card top-up, type*#1345*topupcardnumber# and you will see your new balance on your display! If you press *#1345#you can see your balance on screen.
Type *#31# / *#30# / or *#102# to get the price duration and number of your last call.
Cell broadcast: 050 to display localarea code and postcode.
Free voicemailing! Call 70612 and enter your phone number and voice mail password.

Nokia all codes:

*** WARNING: Using secret codes may be harmful to your phone and result in disabling or worse. Use these codes at your own discretion, we accept no responsiblility for blocked pones while using these codes!!!
IMEI Number
*#06# Cells Identity Code (IMEI = International Mobile Equipment Identity)
XXXXXX XX XXXXXX X
TAC FAC SNR SP

TAC = Type Approval Code (first 2 digits = country code of the approval-country )
FAC = Final Assembly Code: (01,02 = AEG)
(10,20 Nokia)
(40,41,44 Siemens)
(30 Ericsson)
(50 Bosch)
(51 Sony,Siemens,Ericsson)
(60 Alcatel)
(65 AEG)
(70 Sagem)
(75 Dancall)
(80 Philips)
(85 Panasonic)

SNR = Serial Nr.
SP = Spare (always "0")

Software Version
*#0000# shows the software version
Signal Processing
*3370# - Enchanced full Rate Codec (EFR) activation. It will automatically restart.
#3370# - Enchanced full Rate Codec (EFR) deactivation
*4720# - Half Rate Codec activation. It will automatically restart.
#4720# - Half Rate Codec deactivation
Enchanced Full Rate will give you much better sound quality when you enable it. The new Enhanced Full Rate CODEC adopted by GSM uses the ASELP (AlgebraicCode Excitation Linear Prediction) compression technology. This technology allows for much great voice quality in the same number of bits as the older Full Rate CODEC. The older technology was called LPC-RPE (Linear Prediction Coding with Regular Pulse Excitation). Both operate at 13 kilobits.(but you take up more space on the network, so they can charge you more) - Talk-time is reduced with about 5%
Nokia E-Series Secret Codes
Check software version and the release number of your device:
*#0000#

See WLAN MAC address:
*#62209526#

See Bluetooth MAC address:
*#2820#

To hard reset and restore to factory settings:
*#7370# (default lock code is 12345)

See IMEI (International Mobile Equipment Identity) number:
*#06#

Check number where calls are diverted:
*#61#

To display your phone's life timer, type: #92702689#


Please use the following two codes with extreme care:
  • To soft reset the phone and reset phone settings type: *#7780#
  • To hard reset and completely erase all data on the phone and restore it to factory settings, type *#7370#. You'll be asked for a lock code. The default Nokia lock code is 12345.


Sim Clock Stopping

*#746025625#
[*#sim0clock#]
Checks if the sim clock can be stopped. Sim clock stop is a kind of stand-by mode which will save battery time. This code doesn't work with software version 4.59.
It will tell you if it can be stopped or not.


Warrenty Menu

*#92702689# takes you to a secret menu with 6 choices:
[*#war0anty#]
1. Displays Serial Number.
2. Displays the Month and Year of Manufacture (0997).
3. Displays (if there) the date where the phone was purchased (MMYY).
4. Displays the date of the last repairment - if found (0000).
5. Makes you capable of transferring user data if you have the gear for it.
6. Shows how long the phone has been used to talk. This counter is not reset by when you "clear timers" like the counters in the call register.


Bypass the SP lock With a Nokia 16xx/21xx/31xx/51xx/81xx
1. Insert SIM card of different provider.
2. Turn on the phone and press the UP VOLUME key for 3 sec.
Then release it and the phone says PIN CODE?
3. Press the "C" key.
4. Then Press * and wait until it disappears and appears again, then press * one more time and 04*PIN*PIN*PIN#


Nokia Speed Trap Detector Urban Legend spread by Nokia Engineers ;^)
The settings for radar speed traps detector. Your Nokia cell phone can be programmed to pick up radar speed traps, when programmed your cell phone picks up the radar and alerts you on the message alert tone. ( Doesn't work with Nokia 7110! )
1. Enter your menu
2. Select settings
3. Select security settings
4. Select closed user group
5. Select on
6. Enter 00000
7. Press ok
8. Clear back to normal, within a few seconds your phone will display a radar sign with five zero's next to it. It is now activated.
Unfortunately only Nokia phones have this function. The Cell Phone info display needs to be de-activated. Settings -> Phone Settings -> Cell Info display. Each time you turn off your phone, or even each time you loose contact with your carrier, you'll have to activate it again... It is done using steps 1 through 5 above, but the number (00000) will be already on the field as a default. 

Command prompt tricks funny


CMD Fun Tricks and Useful CMD Commands ::::

Here are some fun tricks and fun virus-

(1)If you are using a guest account and run is disabled you can use notepad to open regedit and cmd'
open notepad and type command.com and save it as cmd.bat this batch file will open command prompt.
if you cant open regedit by run open notepad type regedit and save it as regedit.bat double click on this and regedit window will open.

(2)use notepad to abort shutdown -Open notepad and type shutdown -a and save it as shutdown.bat.next time when your computer is about to shutdown double click on this bat file. for other cmd commands open command prompt and type shutdown a and press enter.

(3)cmd fun virus- open notepad and type shutdown -r 10 and save as restart.bat this will restart your computer in 10 seconds if you want to use this for fun paste this file in system 32 and see. computer will restart in every 10 second.

(4)IP command- open command prompt and type ipconfig/all .

(5)How to know your friend's ip when chatting on a messenger. suppose you are using g-talk. ask your friend for a good wallpaper you have downloaded. send this to him .Now open your cmd and type Netstat -n

How hackers hack Facebook Account & How to stop facebook hackers?

Facebook is, undoubtedly, the most popular social networking website with more than 500 million active users. Due to its popularity, many hackers (or should I say crackers?) are actively involved in hacking Facebook accounts of unsuspecting users. This article outlines the many strategies thatsuch hackers use to gain access to Facebook accounts of hundreds of users each day and how you can stop them from hacking your account.
Facebook is one of the prime target of hackers!
Email Address Hack I have always been puzzled by Facebook 's leniency in this matter. All a hacker needs to do is know your email address and he will be displayed a confirmation showing your name even if he enters the wrong password. How easily a hacker can then hack your Facebook account if he 'guesses' your password (if you use a weak password) or answers your security question! This is something I hope Facebook improves on quickly. Until Facebook does so, here are sometricks you can use to protect yourself from this vulnerability.
How to safeguard your EmailAddress?
Just follow these steps:-
1. Hide your Email Address from everyone by going to Edit Profile>Contact Information>Clicking on the icon beside your email address> checking 'Only Me'.
2. Change your primary email address to a one that is only known to you by going to Account Settings>Email> and changing your primary email to the new one (known only to you) and removing your previous email address.
3. For additional security, when in Account Settings, check 'Secure browsing' and 'Send me an emailwhen a new computer or mobiledevice logs into this account' and click Save.
A hacker at work!
Phishing Phishing is one of the easiest ways to trick users into giving out their login credentials. All a hacker does is setup a webpage similar in design to that of the Facebook homepage, attach a server sided script to track the username and password entered and store it in a log. Sending people emails stating that someone tagged a photo of themon Facebook in the same format as Facebook and giving a link below to the phishing website further reduces the chances of itbeing detected as a fake. Sometimes, spam Facebook apps, like those promising to tell who viewed your Facebook profile, automatically post links to phishing websites. A new trend amongst phishers is creating Facebook look-a-like widgets for stealing user's login credentials.
How to prevent yourself from being phished?
At all costs, avoid clicking on suspicious links. Moreover, always check the URL in the address bar before signing in. Avoid logging in through various "Facebook widgets" offered by websites andblogs. Instead, use Facebook's homepage to sign in. Always try to use Safe Search while searching. If you do manage to get phished, report the website so that others may get a warning before visiting it.
Keylogging through Keyloggers Keylogger is a type of computer virus that tracks key strokes. Keyloggers can be installed remotely on a computer system by a cracker to record all the activity that is going on the victim's computer. Keylogging getsmore easy if the hacker has physical access to the victim's computer.
How to stop keyloggers?
Install a good antivirus and update it frequently. Do not click on suspicious links and avoid downloading illegal software. Also, avoid installing free toolbars and other such spam software. Alwaysscan third-person's flash and pen drives before using them on yourcomputer

Login windows 7 without password


Login Windows 7 Computer Without Password

Press Window Key + R together
Type “ NETPLWIZ” in it without quotes and click OK . This will opena User Accounts Window
in This scree Select a User Account
and
uncheck the option which says “ User must enter a use nameand password to use this computer ”
When you click to uncheck this option, it will ask you to confirm the password, enter the password here. After this you aredone.

Windows 7 tricks

Get a power efficiency report:

Windows 7 power efficiency report
A laptop's power efficiency report.

Have a laptop and want to get more battery life out of it? Windows 7 includes a hidden built-in tool that will examine your laptop's energy use and make recommendations on how to improve it. To use it:

1. Run a command prompt as an administrator. To do this, type cmd in the search box, and when the cmd icon appears, right-click it and choose "Run as administrator."

2. At the command line, type in the following:

powercfg -energy -output \Folder\Energy_Report.html

where \Folder represents the folder where you want the report to be placed.


Shake your desktop free of clutter:


If you frequently run multiple programs simultaneously, your desktop can get extremely cluttered. This can get annoying if you're working on one program and want to minimize all the other windows -- in previous versions of Windows you had to minimize them individually.

With Windows 7's "shake" feature, though, you can minimize every window except the one in which you're currently working -- in a single step. Click and hold the title bar of the window you want to keep on the desktop; while still holding the title bar, shake it quickly back and forth until all of the other windows minimize to the taskbar. Then let go. To make them return, shake the title bar again.

You can accomplish the same thing by pressing the Window key-Home key combination -- although doing that is not nearly as much fun.


Windows Management:


By now, you’ve probably seen that Windows 7 does a lot to make window management easier: you can “dock” a window to the left or right half of the screen by simply dragging it to the edge; similarly, you can drag the window to the top of the screen to maximize it, and double-click the window top / bottom border to maximize it vertically with the same horizontal width. What you might not know is that all these actions are also available with keyboard shortcuts:

Win+Left Arrow and Win+Right Arrow dock;
Win+Up Arrow and Win+Down Arrow maximizes and restores / minimizes;
Win+Shift+Up Arrow and Win+Shift+Down Arrow maximizes and restores the vertical size.

This side-by-side docking feature is particularly invaluable on widescreen monitors – it makes the old Windows way of shift-clicking on two items in the taskbar and then using the context menu to arrange them feel really painful.


 Display Projection:


                Had enough of messing around with weird and wonderful OEM display driver utilities to get your notebook display onto an external projector? In that case, you’ll be pleased to know that projection is really quick and simple with Windows 7. Just hit Win+P, and you’ll be rewarded by the following pop-up window:
The Win+P Projector Settings window allows you to quickly switch display settings.
Use the arrow keys (or keep hitting Win+P) to switch to “clone”, “extend” or “external only” display settings. You can also access the application as displayswitch.exe.


                If you want broader control over presentation settings, you can also press Win+X to open the Windows Mobility Center, which allows you to turn on a presentation “mode” that switches IM clients to do not disturb, disables screensavers, sets a neutral wallpaper etc. (Note that this feature is also available in Windows Vista.)


 Opening multiple Instances of the same program

Multiple open instances:

Want to open multiple instances of the same program? Maybe a second command prompt or another application that can be opened in multiple instances? Instead of opening the program again the usual way you can simply press the SHIFT key and left-click on the first instance in the Windows Taskbar to open a second one.

Problem Steps Recorder:


If you ever had to do phone support you know how hard it can be to understand what the user on the other end of the phone did and wants. The Problem Steps Recorder is a sweet little tool in Windows 7 that can be used by the user to record his steps.

psr.exe

All that the user needs to do is start the recorder by entering psr in the Start Menu box and click on Start Record in the program interface. Screenshots will be taken from user actions. It is possible to add comments at any time if the user feels so. The whole recording will be saved as a zip file containing a slideshow of the actions.

Pin Favorite Folders:


Want to add a favorite folders to Windows Explorer to be able to access them faster? Just drag and drop the folder to the favorites menu. It will remain there until you delete it with the delete key again.

Moving Windows and such:


Windows 7 introduces several new keyboard shortcuts for window management. Some useful ones are:

* [Windows Shift Left Arrow] or [Windows Shift Right Arrow] to move windows from one computer monitor to another.
* [Windows Left Arrow] or [Windows Right Arrow] to dock windows to the left or right side
* [Windows Up Arrow] to maximize a window
* [Windows Down Arrow] to restore or minimize windows
* [Windows Home] to minimize all windows but the active one

Shortcuts to start pinned taskbar items:


Pressing [Win Number] will start a new instance of a pinned taskbar item. You should also note that the items can be dragged and dropped into different positions easily.

Use hidden international wallpapers and themes:

When you first install Windows 7, it asks for your language, time and currency. Based on your responses, it installs a set of wallpapers and themes. If you choose English (United States) for your time and currency format, for example, the available desktop backgrounds and themes will include a United States section with scenery from locations such as Maine, the Southwest and so on.

Hidden, though, are background scenery and themes from other English-speaking countries -- Australia, Canada, Great Britain and South Africa. Normally, you can't access those backgrounds or themes, but there is a simple way you can install and use them:


1. In the search box in the Start menu, type "C:\Windows\Globalization\MCT" without quotes and press Enter. (Note: If Windows 7 is installed in a drive other than C:, use that letter instead.)

2. Windows Explorer will launch and show you a list of subfolders under C:\Windows\Globalization\MCT: MCT-AU, MCT-CA, MCT-GB, MCT-US, and MCT-ZA. Each subfolder has wallpapers for a specific country: AU for Australia, CA for Canada, GB for Great Britain, US for the United States, and ZA for South Africa.

For any of the countries whose wallpaper and themes you want to use, go into its Theme folder, for example, "C:\Windows\Globalization\MCT\MCT-ZA\Theme". Double-click the theme you see there (for example ZA).