The so-called "multiline commend" (which can also be used for inline comments) start with /* and end with */. Here is an example:
/* This is a
multiline
comment */
Chat with our AI personalities
// The first type of comment is the single-line comment. // The single-line comment is denoted by a double slash. /* The next type of comment begins with a slash-asterisk, and ends with an asterisk-slash. It is often called a multi-line comment because it can span multiple lines with only one start indicator (/*) and one ending indicator (*/) */ /** * The last type of comment is the Javadoc comment. This * comment type has some guidelines that allows a Javadoc * reader to display information about a Java method or class * by using special tags: * * @param myNum - describe what the parameter myNum is used for * @return - describe what this method returns */ public static int doStuff(int myNum){}
Java is the programming language where substr is used. Substr is a command that returns the characters in a string beginning at the specified location through the specified number of characters.
C and C++ do it for ease of parsing. This way, when they hit a comment start of /*, the parser can trivially scan to the end. Otherwise, it would have to set up and maintain a stack, and then report errors if the comment tokens are unmatched. As to why Java does it, the answer is simple - Java's syntax was designed to emulate C and C++, to trick people into thinking it was just as fast (in the beginning, Java was purely interpreted, so this trick WAS necessary to get traction). If nested comments were allowed, it might trip up some C programmers, and many angry blog posts would be written!
sizeof is not a keyword in Java but many classes have size() or length() methods, which can mean the number of elements, characters, etc. depending on the class.
Pass the code that gets input as a comment. Other way is to delete the code or disable javascript altogether