Skip to main content

Posts

How to print Diamond 💎 with python

Diamond print with * in python print("Diamond printing") num = int(input("Enter num how many num you want : ")) for i in range(num,0,-1):     for j in range(i,0,-1):         print("*", end=" ")     for j in range(2*(num-i)):         print(" ",end=" ")     for j in range(i,0,-1):         print("*", end=" ")     print() for i in range(num):     for j in range(i+1):         print("*", end=" ")     for j in range(2*(num-i-1)):         print(" ",end=" ")     for j in range(i+1):         print("*", end=" ")     print()
Recent posts

Frist thing to do before you start learing programing

Here is the first things you should consider doing before start coding 1) Setup your personal blog on bloger or any free hosting website  On this blog you are going to deploy/uplode your program's code. no need to do any fanci stylish thing just uplode the raw code so that you can access it from any where. Just don't think that first i'm going to learn coding then i will start a website or blog.  Advantages of doing that- a) You can access it frome any where, you can sand it or show it to anyone. b) It will work like a backup, if your computer got corupte the blog will save your life. If you are using GitHub then you dont have to do this but if are learning things seting up a blog is easy. but that dose not mean you should not learn GitHub. GitHub a must learning thing for you if you are learning coding.  If you don't want yo lose your focuse from your coding language you should setup a blog. That all for today have a nice day  Thankyou for reading

Here are three steps to follow for a healthy coding and programing life

People out there are working day and night to learn or earn something but I tell you what, never ever compromise your health for anything.  Here are three steps to follow for a healthy coding and programing life 1) You see my blog name is Night Coder but I do not code in night for me night is made for a good sleep. I name this blog night Coder because I think clearly in night. There is no distractions but you should not work in the if you work then sleep or take a nap in day. You should always take minimum 6 hours of sleep and maximum 8. If have time in the afternoon the take 6 hours of sleep in the night and 1-2 hours in the afternoon. You will feel better fresh and your mind will work with full power. 2) Taking good night sleep is not enough, you have to do some physical exercise also, if you don't want to do that just take a walk of 1-2 km. If you can do jogging or running it will be more beneficial. 3) Don't forget to drink water. In winter the normal drinking water in our

JupyterLab / Jupyter notebook important settings to make work flow easy

when you first start using Jupyter notebook you feel it difficult in comparison to VS code. but believe me it's not that hard. Today i'm going to show you that how can you make your coding experience batter on jupyter without any extension  1) go to settings and click auto close brackets it will automatically close (), '',""

weight converter KG - LBS

  weight = int(input('weight: ')) unit = input ("(L)bs or (K)g: ") if unit.upper() == "L":     converted = weight * 0.45     print(f"you are {converted} killos") else:     converted = weight / 0.45     print(f"you are {converted} pounds")