#πŸ”’ python starter

688 messages Β· Page 1 of 1 (latest)

red trench
#

Anyone have a short and simply easily understandable python guide?...If so please do need to begin the basic quickly and onto the programming.

dapper stagBOT
#

@red trench

Python help channel opened

Remember to:

  • Ask your Python question, not if you can ask or if there's an expert who can help.
  • Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
  • Explain what you expect to happen and what actually happens.

:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.

red trench
#

Also I'm on mobile, so someone please give me a mobile app to use the code

lunar plinth
dapper stagBOT
#
Resources

The Resources page on our website contains a list of hand-selected learning resources that we regularly recommend to both beginners and experts.

echo stone
red trench
#

Whatever man, as long if it's easy, I hate getting links thrown at my face

echo stone
red trench
echo stone
#

instead of your gui apps, you type in something, it spits out back some text

red trench
#

Like a conversation with an ai?

echo stone
#

no

#

like you type in specific commands

red trench
#

Like commands in Minecraft

echo stone
#

yea

red trench
#

Oh

#

Ok sounds good

echo stone
red trench
#

Oh lol

echo stone
red trench
#

Wait install what

#

Oh ok

echo stone
#

you can grab the fdroid app and install it from there, or just grab the termux apk itself

red trench
#

Ye I'm in jt

#

Looks good nice green colors

echo stone
#

search termux on there, download and install, it'll ask for third party app access

#

also note for the future, not everyone asks you to install stuff with good intentions, so double check whatever they send for legitimacy

red trench
#

Ok thanks

balmy cliff
#

You can also try pydriod3

red trench
balmy cliff
#

Its faster than termux

echo stone
red trench
balmy cliff
red trench
#

Oh lol idk what that is

echo stone
lunar plinth
#

Termux is very versatile

lunar plinth
#

Either that or use Github codespaces on your mobile browser

#

Or replit

red trench
#

Idk what that is fr

echo stone
#

the modules are the cement and bricks

echo stone
#

that you put together to make something

red trench
#

Oh

balmy cliff
red trench
#

Oh shortcuts then?

balmy cliff
#

Kinda

#

Seems your too young and new on programing._.

echo stone
#

yeah they're starting from scratch

balmy cliff
#

Well the younger you start the better

red trench
#

Age has to something to do with programming?

echo stone
balmy cliff
#

I also learn programing

red trench
balmy cliff
#

But I know how to code machine language

red trench
#

Confused but I like it

balmy cliff
#

I make cpu In Minecraft

echo stone
# red trench

they said that you seem young and new, not that it's bad or affetcs how you learn

red trench
#

Um still haven't found what termux lol any 1?

balmy cliff
echo stone
echo stone
#

the 4th one

#

the others are add ons you don't really need atm

balmy cliff
#

You can always try using pydriod3

#

Its better as ide

#

I personally don't like nano lmao

echo stone
red trench
#

Sweet buckets

balmy cliff
red trench
echo stone
#

in hindsight yea, use pydroid to get started, switch to termux once you need it's functionality

echo stone
#

more modern

balmy cliff
#

Ow

#

What it looks like?

echo stone
red trench
#

Am I cooked?

echo stone
balmy cliff
echo stone
#

lemme check rq

#

nanao does it well but I forgot if micro deals with it

red trench
balmy cliff
red trench
#

Am I fried?

balmy cliff
#

Just install pydriod3 for now lmfao

red trench
#

Where please

balmy cliff
echo stone
red trench
#

What's ide

balmy cliff
#

Yos

echo stone
#

integrated development environment

balmy cliff
echo stone
#

buncha fancy tools to help you run

red trench
#

Oh so this what I need?

balmy cliff
#

Ofc

red trench
#

Ok downloading

balmy cliff
echo stone
balmy cliff
#

I asking cus I wanna know if it's possible to code only using termux

balmy cliff
#

Got no pc

echo stone
#

I did for about a year

lusty fog
#

vim still exists, so nothing's really stopping you from coding in just termux

echo stone
#

for rust you'll need to proot into linux, but python, perl, c, c++, js worked fine

balmy cliff
#

Its nice if I can se if I get typo error or syntax error before I run it

#

I always have typo errors

#

That's my enemy

echo stone
balmy cliff
#

Woah

lusty fog
#

you should be able to install vscode, if you want a more proper environment that's less of a hassle to setup

red trench
#

Someone have the time to explain all these options meanings?

echo stone
balmy cliff
echo stone
red trench
balmy cliff
#

Then dont enter it

red trench
#

Ye?

echo stone
#

not really the web part as much as the terminal part

red trench
#

Like websites?

echo stone
balmy cliff
#

Kinda

red trench
#

Oh

#

So I just click other

balmy cliff
#

Go

red trench
#

Ok

echo stone
#

btw what version of python does pydroid implement?

#

3.7 or 8?

balmy cliff
#

Hmm 11 I mean

#

I can use match case tho

echo stone
#

so defo 10+ then

#

recent enough

balmy cliff
#

I just use it on my new CPU simulator program

#

@echo stone

echo stone
#

oh damn

balmy cliff
#

Its shell is decent

#

It also has terminal

echo stone
#

yea I used it for a bit

balmy cliff
#

But it's bash

echo stone
#

before ditching it for termux

red trench
#

I made it boys officially did it fr

echo stone
#

now

#

!res

dapper stagBOT
#
Resources

The Resources page on our website contains a list of hand-selected learning resources that we regularly recommend to both beginners and experts.

red trench
#

Not this again

#

😭

#

Nah I trust in u

#

I'ma do it fr

echo stone
#

dw it has categoric seperation

balmy cliff
#

Tbh I didn't read anny documentation

#

I just learn python to simulate a CPU architecture was in my mind

red trench
#

Should I do ada fruit

#

Idk what it is

balmy cliff
#

But I end up learning advance of it

#

@red trench hmm what your first motive on learning python?

lusty fog
red trench
#

That impersonates me

balmy cliff
red trench
balmy cliff
#

For me ML = statistics

#

Lmfao

red trench
#

I'ma need that python book

#

Fr

#

Automate the boring stuff

balmy cliff
#

Forgot it's name

#

Its free and it give very high definition explanation

red trench
#

I want a physical book ngl

#

It would motivate me

echo stone
#

if you prefer it sure, but online resources are a lot more helpful

balmy cliff
#

True

red trench
#

This just says automate boring stuff I'm not going for something out of my way fr

#

I'm too dumb for that

echo stone
balmy cliff
#

I learn only using chatGPT,google, stack overflow,GitHub

echo stone
lusty fog
balmy cliff
#

Sus link

red trench
#

.io hmmm

#

πŸ’€

red trench
#

Am I cooked

echo stone
#

no, you can pick projects you can do on mobile

lusty fog
#

It'll walk you through the relevant math behind machine learning, while giving you practice in what matters. It won't bring you up to date on cutting edge machine learning, but it'll give you a good basis.

red trench
#

Where please @echo stone

red trench
echo stone
red trench
#

Oh

#

So machines is ai

#

Correct

echo stone
#

machine learning is a subcategory of ai

red trench
#

Oh

lusty fog
#

Ah machine learning is the more accurate term for what is commonly refered to as AI. Many people who work in the field prefer to refer to it as machine learning because its a more accurate description.

red trench
#

Engliz what do you recommend I should do instead of machine learning?

#

Or keep it up

echo stone
#

do whatever you want, but building up to machine learning will take a long time

red trench
#

I have no idea what all the other categories do

echo stone
#

and dive into each category a bit

#

see what you like

#

stick with it if it suits you

#

otherwise try something different

red trench
#

He said scripting

#

What can I do with scripting

#

Roblox scripting?

#

Wouldn't that be a language called lua

echo stone
red trench
echo stone
red trench
#

Luau is the other

balmy cliff
#

Lua

red trench
# balmy cliff Lua

Hi I seen you have suggested trying scripting with python, what path does it lead me to and how can I learn what to do with it

balmy cliff
#

Well I personally use programinging for fun

#

Also since I can code I make scripts to easy my works

echo stone
#

scripting is a wide umbrella of things, generally speaking, scripting automates things

echo stone
balmy cliff
#

My first project is very simple

red trench
balmy cliff
red trench
#

Ok can I use scripting to automate me a bot to message me on discord every 5 minutes?

echo stone
#

you can

balmy cliff
#

Lmfao

echo stone
#

*with a bot account, against tos to use botting on a normal account

red trench
#

It's harmless so it wouldn't be tos breaking right

red trench
#

Cuz idk what bot acc is

echo stone
red trench
#

Oh

balmy cliff
echo stone
#

accounts like yours or mine

red trench
#

Oh

#

In what way did you mean against tos to use botting on a normal account

#

Evil spam or just even tryna learn python

echo stone
balmy cliff
red trench
echo stone
#

because determining what is and isn't done with bad intentions is very very hard

red trench
#

I can message my own disc acc

#

Wait I'm confused guys

echo stone
#

not using the app

red trench
#

Dawg what can I do that's not tos on discord 😭

echo stone
balmy cliff
#

Yeah

#

Its no hard

echo stone
#

but let's not dive too far, that's a tad complex

red trench
echo stone
red trench
#

Fr?

#

Complex is not my way fr

#

I'll die

balmy cliff
red trench
balmy cliff
#

I use web hook cus it's cool

echo stone
#

mans just starting he hasn't even done hello world how is an asynchronous api interacting bot not hard

balmy cliff
#

I didn't start at hello world tbh

red trench
echo stone
#

you learn async programming with a discord bot

red trench
#

But not on python so maybe I'm dumb for that

echo stone
red trench
echo stone
balmy cliff
red trench
#

It sounds like something I enable on fps games to boost my performance

balmy cliff
#

Subroutine is not simple

echo stone
red trench
#

Guys calm down focus on me fr fr

balmy cliff
#

Lol

red trench
#

Don't leave me out

#

😭

balmy cliff
#

Well async will call onother thread

echo stone
balmy cliff
#

@red trench learn print function

red trench
#

Ain't it like

balmy cliff
red trench
#

Print(hi)

balmy cliff
#

Use string

red trench
#

What's strit

#

String

balmy cliff
#

"Iam a string"

red trench
#

Ohhh that

balmy cliff
#

Iam_not

red trench
#

Those things

#

'python
Print"(hi jimmy)"
'

#

.

lusty fog
balmy cliff
#

No

red trench
#

I forgot the py thingy fr

#

That change colors

balmy cliff
#

Put it inside the parenthesis

red trench
#

Ohhh

#

Ok

#

Print("parent")

#

Chat I'm smart

#

I did this long ago now I'm redoing it

#

Coding is truly a hard path

balmy cliff
#

caps matter

echo stone
#

if you really want a book this seems to be best suited to you,
skip chapter 2,
switch to termux when you hit chapter 11

echo stone
red trench
balmy cliff
#

Yeah

balmy cliff
#

You'll know it is

#

Easy af

red trench
#

Ye

#

I thought html was easier

#

I mean it kinda is fr

echo stone
#

plain html is easier

red trench
#

But Everytime I stop doing a language I completely forget everything about the commands

echo stone
#

it isn't with css and js in the mix

red trench
#

Or whatever their called

red trench
#

No like basic things

lusty fog
#

syntax is probably the word you're looking for

balmy cliff
#

Html is just like a manual how you want it to be organized

red trench
#

<div> eeee</div>

#

I think that's right

#

No

#

H1 makes header

#

Bruh see

balmy cliff
#

Html has no wrong syntax

#

It will not give error

red trench
#

I didn't even know html had syntax fr

#

I wasn't even on syntax yet

#

πŸ’€

echo stone
#

to be fair, you didn't know the word syntax

red trench
#

Fr

#

Plpp js keep saying it like it's the Roblox executer

balmy cliff
#

Google

red trench
#

😭

red trench
echo stone
red trench
#

"properly" btw fr

echo stone
#

you don't? you learn it from the documentation or a tutorial

red trench
echo stone
#

dw about syntax, it'll just start flowing once you get acquainted with the language

#

this applies to everything

#

not just python

echo stone
#

not like maths, like logical puzzles and stuff

balmy cliff
#

Search "syntax"

#

^^

red trench
#

8/10

balmy cliff
#

Me 1/20000

red trench
#

πŸ’€danm bruh u smart fr

echo stone
# red trench 8/10
  • are you able to solve problems?
  • can you explain how you arrived at your solution?
echo stone
#

πŸ’€

balmy cliff
red trench
#

Nah this homework

red trench
echo stone
#

the second bit is the most important thing when it comes to programming, because you're essentially telling python(or your machine in general) how to solve a problem

balmy cliff
#

True

#

You explain to the computer how to work

echo stone
# red trench What solution

just in general, if I gave you a problem would you be able to a) solve it, b) explain how you solved it step by step

balmy cliff
#

Programing is just a problem solving

#

You find solution using the available resources

red trench
echo stone
balmy cliff
#

Both

red trench
#

Ok what problems do I have

balmy cliff
echo stone
balmy cliff
#

Well make sense

echo stone
red trench
#

Bruh I feel like a ai tryna answer y'all

#

😭

balmy cliff
#

Owh

echo stone
balmy cliff
#

Yeah @red trench do you know if the number is even?

echo stone
#

no pressure

red trench
#

No

echo stone
#

but you can tell correctly 100% of the time right?

red trench
#

Military time or like normal time u see on your phone

red trench
#

πŸ’€

echo stone
#

I'm still asking abt even numbers

balmy cliff
#

You can solve it by making a look up table

red trench
#

Idk what your tryna sayyy

echo stone
#

if I give any number, you don't have each number in your brain going even odd even odd

balmy cliff
#

Where if 1 odd if 2 even ect

echo stone
#

but you can say if any number is even or odd

red trench
#

BRO

#

I'm losing it

balmy cliff
#

Dont

red trench
#

WYM DONT

balmy cliff
#

We are programer not loser

red trench
#

Bro is saying "odd or even odd ect" like I'm in a horror puzzle movie

#

😭

balmy cliff
#

Just answer

red trench
#

Fr

balmy cliff
#

Then

print("can't idenfy what is even or odd yet")
echo stone
red trench
#

Wait how do I know what's odd or even

red trench
#

Not at all

echo stone
balmy cliff
echo stone
#

that's what we're asking you

red trench
#

Oh

#

OHHH

#

Sike I ain't understand nothing yet

#

Kinda

#

So your saying

echo stone
#

is 77 even or odd?

red trench
#

I have to create my own problems and fix them with code right

#

Fr fr

balmy cliff
balmy cliff
red trench
balmy cliff
#

How?

red trench
#

Cuz that number is irrelevant fr

#

I'm smart yall

balmy cliff
#

Well what is irrelevant?

red trench
echo stone
red trench
#

I'm passing these exams

red trench
echo stone
#

this is not an exam πŸ’€

balmy cliff
#

This is not exam

#

We orient you to be programer

red trench
#

Hold up I have Google I don't know what orient mean

balmy cliff
#

RIP

red trench
#

Oh ok

#

There

lusty fog
#

Tbh, I'm not sure what kinda solution yall are expecting. Can't expect them to start talking about modular arithmetics

red trench
#

You guys want me to get familiar with python code

echo stone
echo stone
red trench
#

Ok

echo stone
#

anyway, how did you say 77 is odd?

red trench
#

I'ma be brutally honest

#

It's shape

#

Or

#

Uh

#

It's

echo stone
balmy cliff
#

Lol

red trench
#

Randomly picked fr

echo stone
#

ok lemme back up, what's the definition of even and odd

red trench
#

It's odd that you specifically mentioned 77

balmy cliff
#

I have 2 solution

#

You can make a look up table for every number

echo stone
balmy cliff
#

Or

echo stone
red trench
echo stone
#

😭

balmy cliff
#

Divide it

#

It it give decimal point

#

Its odd

red trench
#

Bro is this even python anymore

balmy cliff
#

Else even

#

Everything here is programing

#

Not only python

echo stone
red trench
#

Why am I learning to program 77??

#

No offense

#

I like this help

#

Lol

balmy cliff
#

You must tell to the computer how to know how the 77 is odd

red trench
#

You refreshed me

#

What's the computer

echo stone
#

python

red trench
#

You mean the terminal thing right

#

Oh python

balmy cliff
#

Computer

#

I build CPU so I have huge knowledge

lusty fog
#

yall are actually trying to teach the theory of computing rn lol

red trench
#

I don't even if 77 is odd or not

red trench
balmy cliff
#

!e

print(77/2,76/2)
dapper stagBOT
#

@balmy cliff :white_check_mark: Your 3.12 eval job has completed with return code 0.

38.5 38.0
balmy cliff
#

If it give .5 then it's odd

#

If not it's even

echo stone
balmy cliff
#

He can't formulate yet

lusty fog
#

How to solve a problem through computation. The idea is for a computer to solve a problem, you need an algorithm. And that algorithm is based in logic, the same logic you would use to solve the same problem.

red trench
#

Ohhh you meant in code

balmy cliff
balmy cliff
#

You can use the way how human solve it and convert the solution into script so computer can solve it insted of you

red trench
#

Oh

#

Like

#

Uh

balmy cliff
#

That's the goal of computer

echo stone
#

to tell python how to solve a problem, you must a) need to know how to solve the problem yourself, b) know to break it down such that you can tell python how to, step by step

red trench
#

Nvm I was gonna say a button and it cost money to press but it leaves me with some change left but I have to script the computer into dividing change back

#

Guys I'm wild guessing

balmy cliff
#

Bro β˜ οΈπŸ’€

echo stone
#

what is the definition of even and odd?

red trench
#

Man

balmy cliff
#

I have easiest way to know if it's even or odd

#

But it's done on the machine

red trench
balmy cliff
#

On the binary level

red trench
#

My solution is Google

balmy cliff
#

That's problem solving

red trench
#

Bro

#

Im about to solve it fr

echo stone
red trench
#

Even I do use Google once I learnt what Google taught me I can remember and reuse it again on whatever problem I need to solve

echo stone
red trench
#

Ain't that what we all do

echo stone
red trench
#

We go through school and use what school taught us to use and do

#

You gotta learn somehow fr

balmy cliff
#

School is bit useless

#

If you get old ull forgot lots of things

red trench
echo stone
red trench
#

Oh wait

#

Is it 77 or definition of even and odd

echo stone
#

definition

red trench
#

Danm

balmy cliff
#

@red trench go get your friend google

red trench
#

Ok

#

I mean

#

If being honest

#

Definition of even is flat and smooth fr

#

That's what I always call it in some things

#

Idk what other solution u got

#

But that's how my human ahh life is

echo stone
#

a serious answer please? we're trying to help, if you aren't co-operating, we can't help you

red trench
#

That's is serious

#

.

lusty fog
#

what's the mathematical definition of even?

red trench
balmy cliff
echo stone
red trench
#

Why am I getting asked definitions of words

#

I mean.

#

It can help

balmy cliff
#

2 is even cus you can cut it in 2 and there will be no number

#

Like
A A A
^odd
A A
^ even

red trench
balmy cliff
#

Its correct

echo stone
#

that you do right?

red trench
lusty fog
#

well its a mathematical concept, there's not a good explanation other than that's how we define even

balmy cliff
#

Now let's go on programing

echo stone
red trench
#

?

#

Is this a ai

#

Hi

#

I wanna learn the quantum physics

balmy cliff
#

Bro

red trench
#

?

balmy cliff
#

Its so broad

red trench
#

Wym

balmy cliff
#

Like way too manny branch

lusty fog
#

I can teach you quantum mechanics if you want. I specialize in computational physics

balmy cliff
#

._.

red trench
balmy cliff
#

Learn quantum mechanics instead

red trench
#

But my friends here are teaching me problem solving

#

Problem solving in python

balmy cliff
#

@red trench go on your pydriod3

lusty fog
#

But the goal of asking you about the definition of even and odd, is that computers don't intrinsically know what is even or odd. You have to design an algorithm to determine that

red trench
red trench
balmy cliff
#

Put this
variable = "I am a string"
print(variable)

red trench
#

I think that's why I'm failing

balmy cliff
#

@red trench explain how that 2 line code works

red trench
#

You can name the variable or not idk I forgot

balmy cliff
red trench
#

Yes I did this before on lua

#

Bro

#

I have PTSD

#

And I live in a place dangerous

#

I wanna go home

balmy cliff
#

What happen is the "=" assigning the variable named variable to have a value of string containing that word

red trench
#

I heard fun shits

#

Gun shots

#

I'm bouta have a panic

#

I'm good

balmy cliff
#

@red trench focus on programing

red trench
#

Bro

#

I'm being serious

#

I fuckin heard fun shots

red trench
#

I'ma keep chilk

red trench
balmy cliff
#

You can defeat PTSD by occupying your mind with other stuff

red trench
#

But it right

balmy cliff
#

So what happen is the "I am a string" is put in the variable named variable

#

And the print use the value of variable and show on the console

#

Now try to print your own text

red trench
#

It got pulled by print(variable) and placed it onto the computer

balmy cliff
#

With different variable name

red trench
#

Right

#

Wym print own text

balmy cliff
#

Print aka show something in the console

#

Its the signature thing on python

balmy cliff
red trench
#

Nah

balmy cliff
#

Fk

red trench
#

Bro

balmy cliff
#

I mean 1+1?

red trench
#

I think someone didd

#

Died

red trench
balmy cliff
red trench
balmy cliff
#

1+1

red trench
#

.

balmy cliff
#

..

red trench
#

2

balmy cliff
#

Nah

red trench
#

I'm smart guys

#

2 and a half

dapper stagBOT
#

@balmy cliff :white_check_mark: Your 3.12 eval job has completed with return code 0.

0b10
balmy cliff
#

Its 10

#

Lmfao

#

Well the math on python is just similar on how you do math on real life

#

Like 1+1-1

#

But the Γ— is *

red trench
#

Isn't that

#

Mathematical operators

balmy cliff
#

Yeah

#

There lots of math operation on python

#

Like mod,floor div ect

balmy cliff
elder shuttle
#

I will archive this post, its nice (for newbies)

red trench
#

Back

#

Kinda

balmy cliff
#

@red trench try to do math and print it

#

Like 1+1

#

Owh I have f-string hack

#

f"{1 + 1 = }" = "1 + 1 = 2"

#

You can use variable

red trench
#

I needed to have talk with someone to calm down

red trench
balmy cliff
red trench
#

What does that

balmy cliff
#

Close this

red trench
#

!close

dapper stagBOT
#
Python help channel closed

This help channel has been closed and it's no longer possible to send messages here. If your question wasn't answered, feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.