python tag

Python is a high-level, interpreted, general-purpose programming language. Its design philosophy emphasizes code readability with the use of significant indentation.

Python is dynamically-typed and garbage-collected. It supports multiple programming paradigms, including structured (particularly procedural), object-oriented and functional programming. It is often described as a "batteries included" language due to its comprehensive standard library.

Guido van Rossum began working on Python in the late 1980s as a successor to the ABC programming language and first released it in 1991 as Python 0.9.0. Python 2.0 was released in 2000 and introduced new features such as list comprehensions, cycle-detecting garbage collection, reference counting, and Unicode support. Python 3.0, released in 2008, was a major revision that is not completely backward-compatible with earlier versions. Python 2 was discontinued with version 2.7.18 in 2020.

Python consistently ranks as one of the most popular programming languages. It is used by many organizations and companies. Pixar, Disney, Instagram and the developers of the Linux Kernel are among many of it's high-profile users, which includes many developers of Free and Open source software.

Reference: WIKIPEDIA

4650 questions


1 answers
36 views
0
How to connect MySQL databases in Python

Please tell me how to access the MySQL database using the Python program.

2 years ago

1 answers
93 views
0
Unicode string appears as false in isinstance()

As far as I know, the integer value should be checked with isinstance(x, int);.However, when I wrote isinstance(x,str);, Unicode is not recognized as a string, so I can't do anything.What should I do?...

2 years ago

1 answers
103 views
0
How do I arrange dict in key order?

{2:3, 1:89, 4:5, 3:0 ->{1:89, 2:3, 3:0, 4:5}How do I arrange it in key order?In other articles, everyone returns the tuple with the ordered value.I need a dict, not a tuple

2 years ago

2 answers
106 views
0
The key and value of the Python dictionary keep changing.

for _ in range(NUM_OF_STRING): sortedDict[_] = {str(string[_]), sortIndexArr[_]}for __ in range(NUM_OF_STRING): print(sortedDict[__])This is the code, and if you run it,{0, ['P', 'S', 'R', 'S', 'P', '...

2 years ago

1 answers
87 views
0
What runs on Jupiter's laptop is not working on Python. (NameError: name 'XXX' is not defined)

class Tensor: def __init__(self, data, shape): self.data = data self.shape = shape self.tensor = shape_data(self.data,self.shape) # <-- * def shape_data(self,data,shape): temp1=[] temp2=[] sh...


1 answers
98 views
0
How does Python initialize a list to zero by a certain length?

In C/C++, int myarr[100] = {};If you write it like this, all 100 elements have been initialized to zeroIn the Python list, mylist = [0 for i in range(100)]Is this the most Python way to write a for se...


1 answers
64 views
0
Python selenium crawling question! (Modify URL)

I'm trying to crawl a product that meets the conditions on a siteI wrote the code using selenium because it seemed to dynamically load the product list.The structure of this site shows the url and the...

2 years ago

1 answers
117 views
0
pg_config executable not found error

I want to install psycopg2, but I keep getting errorsIf you do pip install psycopg2 in the command window, Error: pg_config executable not found.Please add the directory containing pg_config to the PA...

2 years ago

3 answers
103 views
0
How can I change the list element using the for statement in Python?

In Python, you want to change the element that meets the condition to a different value.temp = ['apple', 'banana', 'coke']for i in temp: if i == 'coke': i = 'grape'print(temp)I thought it would be ap...

2 years ago

1 answers
46 views
0
How do I find out the repetitive strings?

You want to create a function that checks whether the string is repeated or not.For example, [ '0045662100456621004566210045662100456621', #Repeat '00456621' '0072992700729927007299270072992700729927'...

« - 279 - »

© 2024 OneMinuteCode. All rights reserved.