« first day (3312 days earlier)      last day (29 days later) » 

12:03 AM
REFRESH! There are 8076 unanswered questions (89.3159 answered)
 
12:16 AM
if your code works then post it to codereview.stackexchange.com - dont post images. — pm100 16 secs ago
 
 
1 hour later…
1:22 AM
If it's working code, Code Review might be more appropriate. A post is limited to 30,000 characters. — Gilbert Le Blanc 15 secs ago
 
 
4 hours later…
4:54 AM
0
Q: Writing a java program that outputs calorie/Macronutrient plan for getting in shape over a certain amount of weeks

Caleb WallaceI am new to programming and was working on a project that calculates an entire "diet plan" as well as a projected weight goal for each week. There are 3 objects that all have methods called on them to print the details for their weight loss plan. Each "person" object contains a name, a current bo...

 
 
3 hours later…
8:03 AM
I’m voting to close this question because it is asking for code review. It should be moved to codereview.stackexchange.comhyde 51 secs ago
 
 
2 hours later…
9:39 AM
Hmm. Shouldn't that be the place for answers rather than questions? SO isn't meant for code reviews. The above design is just flawed. Admin is the Inventory which is either wrong wording or wrong concepts. Both wrong. It's not possible to teach that here even with the best questions you might come up. — qwerty_so 18 secs ago
 
10:16 AM
I’m voting to close this question because this should be asked on codereview or softwareengineering, not on SO. — luk2302 15 secs ago
I am not looking for code review of this code but the concepts that can provide motivation to understanding refactoring, possible overuse. feel free to use your own code or blog to answer. the above code has nothing to do with the question i have asked neither want to know "thiscode specific" refactoring motivation — Navesh Kumar just now
 
10:38 AM
0
Q: Converting Arabic numerals to Roman numerals in AEC

FlatAssemblerHere is my program to convert Arabic numbers to Roman numbers in AEC. You can see it live on my website: Character result[64]; //"Extern" has not been implemented (yet)... Function pointerToResult() Which Returns CharacterPointer Does Return AddressOf(result[0]); EndFunction Function strcat(...

 
11:28 AM
0
Q: UPDATE 1 on Newspaper Bill Calculator CLI with Python (1 of 3, Core)

eccentricOrangeCode is posted after explanation. Due to the size of the project, this is being posted in three separate posts. This also ensures each post is more focused. Post 2 of 3, CLI: UPDATE 1 on Newspaper Bill Calculator CLI with Python (2 of 3, CLI) Post 3 of 3, Database: UPDATE 1 on Newspaper Bill Cal...

0
Q: UPDATE 1 on Newspaper Bill Calculator CLI with Python (2 of 3, CLI)

eccentricOrangeCode is posted after explanation. Due to the size of the project, this is being posted in three separate posts. This also ensures each post is more focused. Post 1 of 3, Core: UPDATE 1 on Newspaper Bill Calculator CLI with Python (1 of 3, Core) Post 3 of 3, Database: UPDATE 1 on Newspaper Bill C...

0
Q: UPDATE 1 on Newspaper Bill Calculator CLI with Python (3 of 3, Database)

eccentricOrangeCode is posted after explanation. Due to the size of the project, this is being posted in three separate posts. This also ensures each post is more focused. Post 1 of 3, Core: UPDATE 1 on Newspaper Bill Calculator CLI with Python (1 of 3, Core) Post 2 of 3, CLI: UPDATE 1 on Newspaper Bill Calcul...

 
12:17 PM
0
Q: the 10001st prime number

Amir MotefakerProblem description: By listing the first six prime numbers: 2, 3, 5, 7, 11, and 13, we can see that the 6th prime is 13. What is the 10001st prime number? Prime number: A prime number is a whole number greater than 1 whose only factors are 1 and itself. A factor is a whole number that can be div...

 
12:42 PM
0
Q: Infix to Postfix Converter in C++

UltimateI have written a program to convert an infix expression to postfix with the help of infix2postfix() function. Please review my code and suggest ways to make it simpler and more readable. Code: #include <iostream> #include <cstring> #include <stack> using namespace std; int isOperator(char x) { ...

 
 
2 hours later…
2:20 PM
-1
Q: How do I get variable values from a function in a pretty way?

HelpNeederStudentIs there a way to do in a nicer way the following thing in Python ? def proving(): a = 4*5 b = 1*9 results = [a,b] return results results = proving() a = results[0] b = results[1] I would like to make a function that makes some calculations and then obtain the values of the vari...

 
 
2 hours later…
4:36 PM
Monking
 
5:27 PM
Monking
 
 
2 hours later…
7:24 PM
Monking
 
7:39 PM
0
Q: Java class to run CompletableFuture<T> instances in batches

William BradleyThis is a utility class for running CompletableFuture<T>s in batches (e.g. to avoid using too much bandwidth making HTTP requests). It seems to work, but I'm a little iffy on the use of my CompletableFutureReferenceWrapper class— I need it so that wrappedFuture can remove itself from running afte...

 
8:29 PM
0
Q: Flooring the BigInt division

ReduFor some reason i have to do var a = -3, b = 2, m = Math.floor(a/b); // <- -2 with BigInts. Despite BigInt's have division operator, it works like flooring if the result is positive and ceiling if it is negative. What i mean 3n/2n = 1n and -3n/2n = -1n where i need -2n. Obviously both 1...

0
Q: Live sync of user text selection on a webpage

FoobarI have, what is roughly, a Chrome extension, that does the following: if 2 users are on the same web page, and user A selects some text, then user B will see the text that user A selected. Roughly, it is as if 2 people are browsing the same web-page from different computers. In this image, we can...

 
 
2 hours later…
10:49 PM
This may be a better question to ask at codereviewPaul T. 17 secs ago
 
0
Q: Dijkstra's algorithm | Leetcode

Aarrav AgarwalWhen I am solving questions on Dijkstra's, I had basically two-way (or Java template for Dijkstra's) to write code for Dijkstra's, but for some questions, both ways are accepted and for some (e.g., https://leetcode.com/problems/path-with-minimum-effort/), anyone is accepted. For a graph (represen...

 
11:21 PM
0
Q: Increment counter on button click

Laila CamposI've wrote a simple JavaScript function to increment a counter after clicking on a button. Here's my code: function incrementValue() { span = document.getElementsByClassName("quantity")[0] let value = span.textContent; span.textContent = Number(value) + 1 } Is my solution to wha...

 

« first day (3312 days earlier)      last day (29 days later) »