Display HTML
<html>
<head>
<title>This is title
</title>
</head>
<body>
Hello world
<!--This is comment section for demo-->
</body>
</html>
Display JQuery / JavaScript
(highlight line number: [2,4,6,7])
$(document).ready(function(){
$("#msgid").html("This is Hello World by JQuery");
//This is single line comment section for demo
/*
This is multiline
comment
*/
});
Display Java
package helloworld;
public class HelloWorld {
public static void main(String[] args) {
// Comment: Prints "Hello, World" to the terminal window.
System.out.println("Hello, World");
}
}
Display Python
(line numbering started from -1)
#! python
'''
Multiline comment demo
'''
# range function
print range(10)
print range(5, 10)
print range(0, 10, 3)
a = ['Mary', 'had', 'a', 'little', 'lamb']
for i in range(len(a)):
print i, a[i]