I made a Java program that uses unicode escaped characters to break a multiline comment and hide some functionality. The program below prints "Hello Cruel World". I'm wondering if this is possible to do in Python (any version). If it is not possible, how is this prevented in the language?
public static void main(String[] args) {
print("Hello");
/*
* \u002A\u002F\u0070\u0072\u0069\u006E\u0074\u0028\u0022\u0043\u0072\u0075\u0065\u006C\u0022\u0029\u003B\u002F\u002A
*/
print("World");
}
private static void print(String s){
System.out.print(s + " ");
}
Note that the unicode is the escaped string */print("Cruel");/*
My fruitless attempt so far...
test = False
#\u0023test = True
'''
\u0027\u0027\u0027
test = True
\u0027\u0027\u0027
'''
print(test)
exec("\u0074\u0065\u0073\u0074\u0020\u003d\u0020\u0054\u0072\u0075\u0065")