CodeNewbie Community 🌱

Cover image for Hardest hello world program of Python lol
Shrikant Dhayje
Shrikant Dhayje

Posted on • Originally published at codewithshriekdj.netlify.app on

Hardest hello world program of Python lol

So This is just for fun.

Most People said to me because I Started Using Python Mostly in my projects.

And They Tell Me That Python is not a Real programming language or Python is For Kids because it is too easy to write.

So for just fun.

I created a repo with various ways of writing Hello World Program In Python.

For Starters It Started Like this.

Program for Beginners

print('Hello World!')
Enter fullscreen mode Exit fullscreen mode

Difficulty Level 0 : Program With Shebang

#!/usr/bin/env python3
print('Hello World!')
Enter fullscreen mode Exit fullscreen mode

Difficulty Level 1 : Program With variable

#!/usr/bin/env python3

message = 'Hello World!'

print(message)
Enter fullscreen mode Exit fullscreen mode

Difficulty Level 2 : Program With Main Condition

#!/usr/bin/env python3

message = 'Hello World!'

if __name__ == '__main__':
    print(message)
Enter fullscreen mode Exit fullscreen mode

Difficulty Level 3 : Program With external function.

#!/usr/bin/env python3

msg = "Hello World!"

def display_msg(message):
    print(message)

if __name__ == '__main__':
    display_msg(message)
Enter fullscreen mode Exit fullscreen mode

Difficulty Level 4 : Program With .env file and running process

#!/usr/bin/env python3
import os
from dotenv import load_dotenv

load_dotenv()  # take environment variables from .env file

msg = os.getenv('MESSAGE')

def display_msg(message):
    print(message)

if __name__ == '__main__':
    display_msg(msg)
Enter fullscreen mode Exit fullscreen mode

running proces at https://github.com/shriekdj/hello-world-py/tree/main/hello_by_legends/legend_hello_4

Repo Is At

GitHub logo shriekdj / hello-world-py

This is an repo of Hello World In Python From Easy to Difficult in Ridiculous Way

hello-world-py

This is an repo of Hello World In Python From Easy to Ridiculous Way

😂

current hardest hello world is given below

#!/usr/bin/env python3
import os
from dotenv import load_dotenv

load_dotenv()  # take environment variables from .env file

msg = os.getenv('MESSAGE')

def display_msg(message):
    print(message)

if __name__ == '__main__':
    display_msg(msg)
Enter fullscreen mode Exit fullscreen mode

It is Available at https://github.com/shriekdj/hello-world-py/tree/main/hello_by_legends/legend_hello_4

It Will Become more difficult by time just wait for it.

Top comments (0)