Which are the valid ways to create DataInputStream streams?

A. new DataInputStream(new File("in.dat"));

B. new DataInputStream(new FileInputStream("in.dat"));

C. new DataInputStream("in.dat");

D. new DataInputStream("in.data","r");

You can do it
  1. Java is fully object oriented programme.
  2. Give file is a file object, which of the following are legal statements to create a new file.
  3. Declaring a method synchronized guarantees that the deadlock cannot occur.
  4. Which of the following methods belong to the String class?
  5. It is perfectly legal to assign a subclass object to a supper class reference.
  6. Submit button always fires doPost(...)
  7. The name of a Java program file must match the name of the class with the extension Java.
  8. We would like to make a member of a class visible in all subclasses regardless of what package they…
  9. Which of the following methods can be used to change the size of a size() *resize()
  10. Which exception is thrown by the read() method of InputStream class?
  11. When X is a positive number the operations x>> 2 and x>>>2 both produce the same result.
  12. In a single Servlet class we can use____________
  13. In the code below, what data types the variable x can have?
  14. Which of the following statements are valid array declarations?
  15. If a=10 and b= 15, then the statement x =(a>b)?a:b; assigns the value 15 to x.
  16. A constructor must always invoke its supper class constructor in its first statement.
  17. executeUpdate(------------) returns ___________
  18. Which of the following are keywords?
  19. Servlet has ___________
  20. class.forName(...) creates an instance of java ODBC driver
  21. What is error in the following class definitions? abstract class xy { abstract sum(int x, int y)…
  22. Which of the following methods can be used to draw the outline of a square?
  23. When we implement an interface method, it should be declared as public.
  24. Which key word can protect a class in package from accessibility by the classes outside the package?
  25. A thread can make second thread ineligible for execution by calling the suspend (-) method on second…
  26. If m and n are int type variables, what will be the result of the expression'm % n' when m = -14 and…
  27. A Java monitor must either extend thread class or implement Runnable interface.
  28. The methods wait() and noify() are defined in
  29. When we implement the Runnable interface, we must define the method
  30. Which of the following statements are true?