-
What is the output of this program?
import java.net.*;
public class networking_Length
{
public static void main(String[] args) throws Exception
{
URL object = new URL("https://www.interviewmania.com/java/programming");
URLConnection object0 = object.openConnection();
int length = object0.getContentLength();
System.out.print(length);
}
}
Note: Host URL is having length of content 256.
-
- 260
- 256
- Compilation Error
- Runtime Error
- None of these
Correct Option: B
256