Visit my website at https://www.thenewboston.com/ for all of my videos and tutorials! Have questions or looking for source code? Check out the forum at ...
I started in VB, where the program itself doesn't store anything. starts
clean each time it debugs. where does python store its variables? and does
it remember variables when starting new sessions, or does it start fresh
every time you boot up?
Anyone know why this is happening to me??
I am on the verge of jumping of the nearest high place... -_-
------------------------------------------------------------------------------------------------------
Traceback (most recent call last):
name = input ("What is your name? ")
File "", line 1, in
NameError: name 'bob' is not defined
I'm trying to learn a programming language and i'm following your tutorials
but i don't know if i should learn Python or Java...wich one is more
usefull now? Python seems to be easier to learn but i don't know what i can
do with that. I was trying to make a program for inventory controll with
java and it's really hard. Any advise? Should i learn Javascript for web
oriented things?
+Azmodan86 I just started really committing myself to learning Python in the last few weeks (some old experience with html/css/php/failed python attempts lol) and lemme say that once you commit yourself to it, it becomes easier and sensible to learn. Don't get caught up on Which languages to know, because you're Going to have to learn more than one language anyway in the future, as you should. I now have a good idea what programmers mean when they say learning your first language makes learning the others easier. It's all just logical commands that do similar things, even if the commands themselves are different.Also, what platform you're on and what you want to do in the future will play more of an importance in decide what languages to learn in the future. If you want to be a web designer/server side programmer, then Python and others like Ruby/JavaScript are great. If you want to create iOS/Mac apps, Objective C and the newer one Swift are good to learn. If you want to be a Windows platform programmer, C++, C#, and the web tech Micro uses should be your focus.Also note that Windows, OS X, and Linux All make heavy use of regular C at the lower levels. Take that as you will.But the thing about Python that I'm learning is that it's sorta like a Swiss Army knife no matter what type of programmer you want to be. Good to have in your backpocket to make your life easier. I may be a bit off though. I'm still a noob. :PLearn Python. Then learn other languages. That's what I plan on doing. (Stay away from Perl though. I hear it's a shitfest. :P)
+Kartik Kapila You don't need the r at the start of the string, you don't have any backslashes that you want ignoring. This code works instead print ('He said, "She\'s upset"')
Visit my website at https://www.thenewboston.com/ for all of my videos and tutorials! Have questions or looking for source code? Check out the forum at ...
if I write print("x")
print("y")
output--> x
y
what if I want it as xy ??
and if I said x=20
y="bomb"
print(x,y)
output--> 20 bomb
what if I want it as 20bomb
hey guys I need some help. so i decided to make a cute little averaging
program based on the ideas in this video. my code is as follows
print("+-----------------+")
print("+ averaging program +")
print("+-----------------+\n")
print("How many numbers would you like to average")
numbers = int(input())
values = [ ]
total_number = 0
print()
for n in range(numbers):
print("value of number", n+1)
values[n] = input()
print()
for n in range(numbers):
total_number += values[n]
total_number /= numbers
print('The result is\n', total_number)
but whenever I use this it gives me a traceback error
+-----------------+
+ averaging program +
+-----------------+
How many numbers would you like to average
5
value of number 1
1
Traceback (most recent call last):
File "C:/Users/*******/Pycharm projects/untitled/calc.py", line 13, in
values[0] = input()
IndexError: list assignment index out of range
Process finished with exit code 1
help?
+youpoopmasa78 try using thisfor n in range(numbers): print("value of number", n+1) values.append(int(input())) print()Since values is an empty list you can't use "n" which doesn't exist yet. And i added int() func. before input because you will do mathematical operations with those values. So they have to be integers. I'm a new learner so please correct me if i said anything wrong.
+Meville Pereira yes they are strings but only the index number of a list starts counts from 0 but the len operator counts the characters which starts from 1
Python Programming Tutorial - 2 - Numbers
Visit my website at https://www.thenewboston.com/ for all of my videos and tutorials! Have questions or looking for source code? Check out the forum at ...
hi as we now
3/2
1.5
and
3//2
will give in python 1
but
3%2 must give 5
but it giving 1 too
there is a reason related to math and floating point as i think but can you
explain it to me here sir
+breon johnson This is very very basic if you can't do this you should probably go to Khan Academy brush up on some maths for a week or two then come back and do these videos.
+breon johnson you're sadly mistaken my friend. if you truly want to learn programming you're going to wanna brush up on your mathematics. just practice and stay focused
Visit my website at https://www.thenewboston.com/ for all of my videos and tutorials! Have questions or looking for source code? Check out the forum at ...
+Völundr Frey Well, C++ isn't really a low-level, it's medium-level. Meaning it is a high-level language, but you can also mix the code with low-level programming and some low-level functionality. You can use Assembly in C++, so it kinda makes it medium-level.
+XBR4Da This is a high level language and C++ is a low level language. Run times could be upwards of 200-300 times longer because of the simplicity. It's not bad because of that, just a completely different language. Apples and oranges.
Hi Bucky,
Would it also be possible to slice out of a lists elements?
I mean this:
example = [ 'cat.jpg' , 'dog.bmp' , 'mouse.gif ]
and I would like it to be changed to this:
extensions = [ 'jpg' , 'bmp' , 'gif' ]
I tried this:
for i in example:
print i[-3:]
It prints the extensions, but how can I assign these new elements to a new
array called extensions?
You got great videos!
>>> example=[1,2,3,4,5,6,7,8]
>>> example[2:6]
[3, 4, 5, 6]
>>> example[3:7]
[4, 5, 6, 7]
Q : why it takes the last number i select ? maybe is it because its a newer
version than this bucky uses ?
thank you im applying for a job with financial unix background currently
using perl and java these tutorials are so helpful been programming for 25
years love the fresh perspective! :) thank you again
+Troy Van der That'd be a very long video. I am currently making a python for finance series, going from the basics onward, however. You may be interested in that one. PyQT series is coming first, then that one.
Python Programming Tutorial - 11 - Continue
Visit my website at https://www.thenewboston.com/ for all of my videos and tutorials! Have questions or looking for source code? Check out the forum at ...
I find the number of tutorials extremely excessive.
A tutorial for 1 keyword?!
I feel like I am treated like a retard who can only absorb one concept at a
time.
+Tobias Jost it's because it's mostly directed at those programming for the first time in their lives. Otherwise, I think that if you grasp the language's syntax, you can simply look at his playlist's videos' titles as a guideline and simply google how to do them to save your time =)
+Tobias Jost There are plenty of video series that cram lots of information in at once. The reason I lot of people seem to enjoy Bucky's videos is exactly the reason you dislike them. He goes slowly over each topic, so that you can fully grasp them. Not everyone has much prior experience in programming; therefore, the concepts can be quite confusing at first. Personally, I watch all his videos at 2x speed, which seems to help when I'm finding the topic a bit easy.
you could have just done it without using continue like this
numberstaken=[2,5,12,13,17]
print("these are the jersey number still available")
for n in range(1,20):
if n not in numberstaken:
print(n)
anyways good work bucky nice tutorials!
+libral lawrence Remove all '' from numberstaken. With '' they are not numbers, but strings.
Python Programming Tutorial - 4 - Slicing up Strings
Visit my website at https://www.thenewboston.com/ for all of my videos and tutorials! Have questions or looking for source code? Check out the forum at ...
Hey something you may want to know. In python 3.4 they changed the counting
system so that 0 is just the empty space that comes before the word. Get
3.4 and paste this in and see for your self.
users = "muffin"
users [1:2]
ALSO TRY
users = "muffin"
users [0:1]
There's no way I can get the IDLE downloaded in my mac. I'm using the Text
Wrangler, how can I execute the variables like print or user while
programming?
+Guilherme Resende As long as i know, when you download python, it includes the IDLE, named IDLE (Python 3.5 32-bit), i'm a windows user so i don't know about python on mac.
+Tanmay Sachan cause when you type..example(type this in ur python IDLE):user = "Banana Split" (enter) then type: user[7].it prints out "S" bcause it doesn"t counts the space that you"ve insert.
Programming a Custom Backdoor in Python
Howdy! Today we are going to program a simple custom backdoor -- around 10 lines of code -- that totally avoids detection by every a/v out there. We're gonna ...
+Technic Dynamic Good job but this will only work on your private network
because you connect to the private Internet protocol address. If you wanted
to make this external you would make it connect to your external internet
protocol, port forward your external internet protocol to a server on your
computer, and there we go.
+Craig Lutic Yes I am aware of how to do this manually, and I do show this in other parts of video but I wanted to know how to do port forwarding using only Python code :P
+Technic Dynamic You didn't have to use netcat for your private connection, you could of just created a server and let the client connect to the server, or vise versa. If you wanted your program to work over External IP you would have to go in your router settings and port forward your computer on a specific port(starting <> ending), then bind/connect your socket to that address.
Hey Craig I am aware of port forwarding and I show this in the other parts to this video. I would love to know how to do that using Python only and not having to access the router send me a message if you can =)