Questions tagged [python]

Python is an interpreted, general-purpose high-level programming language whose design philosophy emphasizes code readability. Use the python tag for all Python related questions. If you believe your question may be even more specific, you can include a version specific tag such as python-3.x.

Filter by
Sorted by
Tagged with
4
votes
2answers
104 views

Password Generator with injected password model

I'm getting started with Python and one of the beginner projects to learn the language was a password generator (one of the dozens already in CodeReview). I have a C# and JS background so I want to ...
4
votes
0answers
28 views

My Blackjack Game in Python

I am a beginner programmer ( just recently picked it up ). I just completed my first ever project, that is creating a Blackjack game in Python. I would like to know your opinions about it and how it ...
0
votes
0answers
10 views

Loss function in python is a bit cumbersome

This is my first post here. I seek to improve my way of writing Python and C++ code. I hope I can also contribute to others when I have increased my skill. Here is a python function I have for a ...
2
votes
0answers
36 views

Python script to parse XML file into Json

How are you doing? I have to make a script to parse an xml input file to a json file. I tried to do my best, but it will be nice if you could check it and help me to improve it. The idea is that I don'...
-1
votes
0answers
16 views

Cannot insert a vertex into a graph [closed]

I'm trying to create a graph for a kind of social network analysis and I cannot use Networkx library (it is for an academic project). I have a csv file with data like this: ...
0
votes
0answers
17 views

addition of two list elementwise with abortion if condition satisfied python

I have a function that sums two arrays element-wise and stops if the sum at a certain index is greater strictly than 1. This function is called several times and though it is not the bottleneck of my ...
0
votes
0answers
20 views

Fitbit dashboard with Python [closed]

...
2
votes
1answer
33 views

Very slow Discord bot to play music

I have been writing a discord.py bot, running on replit.com. I gotten to the music bot part after finishing the queue part. My code is logically correct; however, the code is way too inefficient ...
-2
votes
0answers
12 views

How can I save strings appended to a list in python? [closed]

I want to know if I can add values to a list and they will be saved the next time I run the code. For example: ...
1
vote
1answer
37 views

Robot OOP Class in Python

Hello everyone! Here is the thing. So I wanted at first to create Robot class, I want him to move around some board. Maybe 10x10 or something like that, then i wanted to invent a Robot fights class, I ...
2
votes
1answer
50 views

Chain of Responsibility design

I'm trying to design a chain of responsibility pattern. It slightly differ from traditional way when handler does only one action on a request, f.e. handles http response considering status code. But ...
-2
votes
0answers
38 views

What is more efficient? using conditions before for loops? or vice versa? [closed]

I'd like to know what is more efficient and performant for the following two cases: Using conditions before for loops: ...
0
votes
2answers
32 views

Relative Strength Index algorithm for stock values

This is an Relative Strength Index algorithm able to buy and sell stock based on values from basic stock CSVs. It works correctly and well, but I'm not sure if it can be better optimized as it ...
2
votes
0answers
26 views

AStar Implementation and Efficiency

This is my implementation of an AStar-like algorithm for maze solving. A quick summary of the problem I am trying to solve with my algorithm might be: A simple binary maze is given to you to solve, ...
3
votes
1answer
45 views

Verifying calibration process on IoT device, python script

I have an IoT device with accelerating and gyroscope sensors. before my device can be used it needs to be calibrated. Basically, it means that I do measures for XYZ axes and for the gyro movements and ...

15 30 50 per page
1
2 3 4 5
904