def weird_string(s):
    answer = ""
    for i in range(len(s)):
        if i % 2 == 0:
            up_word = s[i].upper()
            answer += up_word
        elif i % 2 != 0:
            down_word = s[i].lower()
            answer += down_word
            
    return answer
    
s = "try hello world"
ret = weird_string(s)
print(ret)

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: