For this Question: Given a string S (containing only letters of the English alphabet), find all the capital letters in it (in exactly same order as the string)

Note:- It is guaranteed that the given string will contain at least one capital.Input contains a single line containing the string S.

Constraints:-
1 <= |S| <= 100Print all capital letters present in the string separated by space, in the order of their appearance in the main string.Sample input:-
AbcdEF

Sample Output:-
A E F

Sample Input:-
NewtonSchool

Sample Output:-
N S, I have written this Solution Code: n=input()
for element in n:
    if element.isupper():
        print(element,end=" "), In this Programming Language: Python, Now tell me if this Code is compilable or not?