Learn Encapsulation by Building a Projectile Trajectory Calculator - Step 21

it worked because there is a coordinates variable declared at the bottom of the code, it will give you the wrong value tho

oh right thanks that makes sense

oh right thanks that makes sense, im stuck on the alignment part even chatgpt isn’t answering me properly

do not use chatgpt, you will get into bad habits

what’s your output now?

1 Like

⊣     ∙       
⊣  ∙∙∙ ∙∙∙    
⊣ ∙       ∙   
⊣∙         ∙  
⊣           ∙ 
⊣            ∙
⊣             
TTTTTTTTTTTTT

that is my output i need the x axis to go right a little bit im so sure we done a aligment thing in a earlier project i can’t seem to find it tho

please use the three backticks to format your code, it’s all squashed to the left

why not use chatgpt tho i just tell it to ask me questions while explaining it to me and if i get the questions wrong guide me to the asnwer

how? i can’t figure it out, do i actually use backticks in my code?

follow these instructions, you should for code in general, but now without you can’t show your output properly

When you enter a code block into a forum post, please precede it with a separate line of three backticks and follow it with a separate line of three backticks to make it easier to read.

You can also use the “preformatted text” tool in the editor (</>) to add backticks around text.

See this post to find the backtick on your keyboard.
Note: Backticks (`) are not single quotes (').

chatGPT doesn’t explain things, nor can help you reason toward a result. ChatGPT puts together words in a way that seems natural, but there is no garantee that the words will be put together to say something correct

2 Likes

I’ve edited your code. You can edit it again to see how to format code.

1 Like

Don’t overthink this either. Do it in the simplest way possible. How would you shift a string 1 char to the right?

Look at the example again and see what you are missing in your output.

1 Like

yeah but that’s what it looks like on the terminal it’s squashed to the left

the thing is i don’t know what line to modify i need to use a space i know i would but i don’t know what line to implement this on, i am able to modify the y axis by using a space. However when it comes to the x axis nothing fits only option i see really is alignment, how could i actually fix this? i’ve put a space in the most random places and it doesn’t work

for once i managed to use problem solving skills by looking at others code and implementing certain areas, i have managed to succeed in doing this task

1 Like

Feels good, keep crushing it. :muscle:

1 Like

thanks, i am using the book python crash course by Eric matthes third edition, is that a good way of learning code? I was reading deep work by cal newport and he was talking about this man who wanted to learn programming fast and how he got a textbook and studied it making notes. Are you familiar with that type of learning, and do you recommend it.