Code Review Stack Exchange Community Digest

Top new questions this week:

News API in Python

Why I made it I’m building a voice assistant and thought it would be great if it could deliver news updates. What it does It cleans up the user’s query, determines whether it refers to a news category ...

python api python-requests  
user avatar asked by Chip01 Score of 8
user avatar answered by Kate Score of 13

Find the nearest school to you

I have created a text-based program that finds the nearest school using your coordinates. The CSV DataFrame is available through LimeWire. I'd like to know how I can improve it. ...

python  
user avatar asked by Litcoder Score of 7
user avatar answered by J_H Score of 4

MinMaxStack - tracks minimum and maximum values

I'm implementing a MinMaxStack<T> in C++20 that tracks minimum and maximum values. The class needs T to support ...

c++ comparative-review stack c++20  
user avatar asked by sam Score of 5
user avatar answered by Toby Speight Score of 4

Transform dataset coordinates from Lambert Conformal Conic projection to WGS84

I am trying to convert a dataset which has a Lambert Conformal Conic projection to the classic WGS 84 with Python. Unfortunately, the dataset does not have a defined EPSG code, but the general ...

python coordinate-system  
user avatar asked by Lefteris Mezilis Score of 5
user avatar answered by toolic Score of 4

Bash script for manually cleaning up the Traefik access log file and limiting it to a maximum of 50 MB

I have written a short bash (or POSIX-compliant) script to clean up the Traefik access log file and limit it to a maximum of 50 MB. I would like to know what you think of it. Any suggestions are ...

bash logging docker  
user avatar asked by Tobias Grothe Score of 5
user avatar answered by Toby Speight Score of 7

News API in Python - Take II

From my previous post, I tried to take into account all of the nice answers made by Kate, Chris, J_H, Booboo and mudskipper Changes made In short, I attempted to apply all of the following: API key ...

python api python-requests  
user avatar asked by Chip01 Score of 5
user avatar answered by Chris Score of 4

On the absence of protected member concept in javascript

I wanted to create a protected member in a javascript (ES) class but, of course, there is no such concept. So I devised a way that would let me create a member or something that ”no once could touch ...

javascript  
user avatar asked by Abet Giron Score of 1

Greatest hits from previous weeks:

Dropping rows from a PANDAS dataframe where some of the columns have value 0

I am dropping rows from a PANDAS dataframe when some of its columns have 0 value. I got the output by using the below code, but I hope we can do the same with less code — perhaps in a single line. df:...

python pandas  
user avatar asked by pyd Score of 9
user avatar answered by jezrael Score of 13

Python username and password program

Can the following code be simplified? I think that the program that I have created is very excessive and quite slow. The program runs fine, but I would like to understand if this could actually be ...

python beginner python-3.x authentication  
user avatar asked by Greg Score of 10
user avatar answered by Quintec Score of 10

Bank ATM program in Python

For homework, I have to code a program in Python that effectively simulates a bank ATM. ...

python python-3.x homework finance  
user avatar asked by MaxxB Score of 6
user avatar answered by flakes Score of 9

Grouping elements in array by multiple properties

During work, I was given this task: to group elements with similar properties in the array. In general, the problem is as follows: ...

javascript sorting properties  
user avatar asked by Saike Score of 66
user avatar answered by konijn Score of 65

Euclid's Algorithm (Greatest Common Divisor)

According to Donald Knuth in "The Art Of Computer Programming", the following is how to find the greatest common divisor of two positive numbers, m and n, using Euclid's Algorithm. Divide m by n ...

c algorithm mathematics error-handling  
user avatar asked by Fiddling Bits Score of 17

Changing color on button click

I have an html button that when the user clicks the button it will change color from blue to red and back. Is there a better way to do this in jQuery? HTML/jQuery ...

jquery html  
user avatar asked by Aaron Score of 5
user avatar answered by Malachi Score of 9

Dynamic filtering and sorting with Entity Framework

I'm developing an application using ASP.NET MVC 3 and Entity Framework 4.1. In that application I have a lot of paged lists. Users can filter and sort these lists. This results in code like the one ...

c# asp.net-mvc-3 entity-framework  
user avatar asked by Kristof Claes Score of 39
user avatar answered by shuniar Score of 16
You're receiving this message because you subscribed to the Code Review community digest.
Unsubscribe from this community digest       Edit email settings       Leave feedback       Privacy
Stack Overflow

Stack Overflow, 14 Wall Street, 20th Floor, New York, NY 10005

<3