5 years ago in Java Socket Programming

What is the output of this program?

import java.net.*;
class networking {
public static void main(String[] args) throws Exception {
URL obj = new URL("http://www.sanfoundry.com/javamcq");
URLConnection obj1 = obj.openConnection();

[A] html
[B] text
[C] html/text
[D] text/html
Next Question

Overall Stats

Attempted 109
Correct 14
Incorrect 32
Viewed 63


Tsega Asresa Mengistu
Tsega Asresa Mengistu - 4 days ago

Tsega Asresa Mengistu from Dessie, Ethiopia is saying html/text is correct answer

Vaibhav Bisht
Vaibhav Bisht - 4 weeks ago

Vaibhav Bisht from Dehradun, India is saying html is correct answer

Zo Go
Zo Go - 4 weeks ago

Zo Go from Casablanca, Morocco is saying text/html is correct answer

pavithra p
pavithra p - 8 months ago

pavithra p from Bengaluru, India is saying text/html is correct answer

Rania Waleed
Rania Waleed - 9 months ago

Rania Waleed from New Cairo, Egypt is saying html is correct answer

Related Questions

Which of these methods is used to make raw MIME formatted string?

  • [A] parse()
  • [B] toString()
  • [C] getString()
  • [D] parseString()

Which of these is an instance variable of class httpd?

  • [A] port
  • [B] cache
  • [C] log
  • [D] All of the mentioned