« first day (2939 days earlier)      last day (1079 days later) » 

12:02 AM
RELOAD! There are 7591 unanswered questions (89.4286% answered)
 
0
Q: Go Brainf*ck Interpreter

Anthony GedeonRecently wrote a brainfuck interpreter in Go. Here's the Github Repo Brainfuck Areas that need work The parsing for brackets [] is still buggy and is known to fail when dealing with nested loops i.e [[]] any hints on how to approach the problem would be greatly appreciated. After looking at this ...

 
12:54 AM
0
Q: What's the best practices I ain't using in this code?

Monty_emmaI have a fundamental but interesting question. I have written this python code which checks the payload sent from a specific IoT topic. First, I would love to get honest feedback and learn how to improve my code to be most efficient, readable, and straightforward. Second I would like to know when...

 
For a review of working code like this, really you should post it on CodeReview.SE. This decomposition is overly complicated; you don't need to keep calling player() and keep recounting the number of pieces played. player() seems redundant most of the time, you just have a Board class and keep integer counters X_pieces, O_pieces which each have values 0..3. — smci 8 secs ago
 
 
1 hour later…
 
2 hours later…
4:03 AM
Monking
 
4:15 AM
0
Q: How can i increase searching in this code

Agent_AI have made a simple contact management in c++ it's my second sort of project.I'm pretty sure it can be done more better and I could decrease it's runtime but I just joined the CPP community this year. So can you review my code? What's this all about? ~It's A CUI based contact management system t...

 
5:42 AM
possible answer invalidation by JimmyHu on question by JimmyHu: codereview.stackexchange.com/posts/260989/revisions
 
5:57 AM
possible answer invalidation by JimmyHu on question by JimmyHu: codereview.stackexchange.com/posts/260989/revisions
 
6:25 AM
@Duga Its a little bit of grey area. Answerer states
> I've voted to close this question... However this is too big for a comment, so I'll delete this answer tomorrow unless the question amended (or it gets deleted in the meantime)...
but IMO the answer has some valid and good pointers and the reason for the close vote seems to be not correct.
Don't delete your answer, because your main concern about CurrentUser is IMO not correct. CurrentUser is created inside the Try block. See first version inside the edit history of the question. Nevertheless your answer shows some valid points. — Heslacher 13 mins ago
 
 
1 hour later…
7:35 AM
0
Q: BottomNavigationView not visibile in all Fragment

rikiI have a question the kotlin code below defines a BottomNavigationView is visible only in the activity_main and not in the fragments present in the bottombar navigaiton, the gist is that the bottom bar is visible only on the first page and not in the remaining fragments, what is this due to? what...

 
7:47 AM
 
8:43 AM
If you've tested this (e.g. in a debugger) and you think it works, you could post it on codereview.stackexchange.com if you're looking for whether feedback on how well-written it is. (e.g. your loops are compact, with branch conditions at the bottom where they should be, without wasting instructions on push/pop to use loop for both loops or anything silly like that. So it's probably decently efficient for 8086, but xchg-with-mem will be very slow on modern x86: implicit lock) — Peter Cordes 12 secs ago
 
0
Q: Binary Search Algorithm Difference

snrAs far as I test, there is no any bug point tested. However, I wonder that if there is a problem with the usage of arr.Length or arr.Length - 1. // size is array length private static int BinarySearch(int[] arr, int element) { int begin = 0; int end = arr.Length; for (; begin < end ;...

 
9:15 AM
-1
Q: replace number to word

mark saadString s = input.next(); for (int i = 0; i < s.length(); i++) { char c = s.charAt(i); switch (c) { case '0': System.out.println("zero"); break; case '3': System.out.println("three"); break; case '8': System.out.println("eight"); de...

 
10:06 AM
0
Q: Minimax algorithm efficiency

one_hell_of_a_guyI'm programming Tic-Tac-Toe using minimax algorithm with alpha-beta pruning after taking Harvard's CS-50. My logic is working perfectly, except for the return time of minimax (especially on the first call, when only one player played). I was thinking of replacing the extra recursive call of minim...

 
10:33 AM
If this code is working, please post this in Code Review after reading their help pages. — adiga 20 secs ago
 
10:56 AM
0
Q: Handling multiple optional parameters in Spring

KalichI have an endpoint in my RestAPI which can receive 3 optional parameters and then find information in the database with these parameters, also it is possible to combine the parameters. So, in my controller I take a Map<String, Object> which contains these parameters and then pass it to the servic...

 
This question is better suited for codereview.stackexchange.com. — tony19 12 secs ago
 
11:21 AM
0
Q: build a Xbonacci function that takes a signature of X elements ,each next element is the sum of the last X elements ,and returns the first n elements

Amirthis is a kata from codewars, here is the description of the kata: think of a Quadribonacci starting with a signature of 4 elements and each following element is the sum of the 4 previous, a Pentabonacci (well Cinquebonacci would probably sound a bit more Italian, but it would also sound really a...

 
 
1 hour later…
1:27 PM
0
Q: Speed up interpolation in Python

Masoom KumarI am trying to plot heatmap with three variables x, y and z, each with vector length of 932826. The time taken with the function below is 28 seconds, with a bin size of 10 on each x and y. I have been using another program where the same plot happens in 6 - 7 seconds. Also, I know that the plot f...

 
1:53 PM
If the code you have works, and you're willing to share more of it, you may want to check their help center to see if your question is on topic for Code Review. — Heretic Monkey 40 secs ago
 
 
1 hour later…
3:07 PM
Monking
 
3:32 PM
0
Q: counting number of words from a text file in C and printing results in another text file

Sara AgbariaThe code: #include <iostream> #include <stdio.h> #include <string.h> char filename[] = "11.txt"; char filename1[] = "2.txt"; FILE* ptr, * resultptr; char string[100]; char words[100][100]; int len = sizeof(filename) / sizeof(char); int i = 0, j = 0, k, length, count; int main() { fopen_s(&ptr, ...

 
3:57 PM
0
Q: Identify valid 8 card poker straight

Aloysius RebeiroWrite a code to identify a valid straight of eight cards, e.g. ['4H', '5S', 'AC', '7C', '8H', 'AH', '0S', 'JC']. Note that the card combination may include Wilds (as we see in our example, with the Ace of Clubs standing in for a Six and the Ace of Hearts standing in for a Nine), but must include ...

 
Monking
 
4:48 PM
in The Nineteenth Byte, 4 mins ago, by pxeger
@cairdcoinheringaahing why is the bot so emphatically female?
^ pxeger was referring to Duga. May I ask why Duga is "so emphatically female"?
 
5:03 PM
@user @skiwi do you know? Alternately you could ask Simon in the Factorio room
 
If it works then CodeReview may be the place. — Solar Mike 53 secs ago
 
@Peilonrayz Thanks, I'll do that
 
5:26 PM
@SolarMike: Yes the code does work, I tried on a smaller sample dataset. However, as I start increasing the rows, it takes too long to process all 9000*9000 calculations. Thanks, I will give CodeReview a try. — Helixeye 16 secs ago
 
 
2 hours later…
7:42 PM
@AndrewL64 I wasn't asking for a code review. I just gave a loose example to supplement my train of thought - this specific code wasn't actually used. — mermi 12 secs ago
 
 
1 hour later…
8:47 PM
@Peilonrayz OP gave the impression that their hypothetical code was working but they are trying to find out if given approach is a "good strategy" for avoiding repetitive code. That sounds like a code review regardless of whether it's off-topic or not to StackOverflow. Also, note the bolded and caps PROBABLY. — AndrewL64 33 secs ago
@mermi Regardless if your code is hypothetical or not, your question gave the impression that you have working "example" code and want to know if your "example" code was a good "strategy" for handling multiple users. That sounds like asking for a code review tbh. Also, as mentioned in the other comment, note the bolded and caps PROBABLY. — AndrewL64 35 secs ago
 
9:07 PM
"OP gave the impression that their hypothetical code was working". Please familiarize yourself with Code Review's rules when recommending people to post on CR, "Questions should not contain purely generic, hypothetical code". In your own words the question would be a bad fit for CR, which is why you shouldn't close ("I’m voting to close") because of mere assumption of other site's rules. — Peilonrayz 49 secs ago
 
9:49 PM
Please repeat on topic and how to ask from the intro tour. “Rewrite my program” is not a Stack Overflow issue. We expect you to make an honest attempt, and then ask a specific question about your algorithm or technique. However, since you have a basic idea of what you want to attack, this might work on StackExchange/CodeReview. — Prune 49 secs ago
 
10:38 PM
0
Q: calculations for health/attack/defense parameters to game characters

AlbertJI'm developing a RPG game and being blocked by the settings of HP(hit points/health points/health power), attack and defense for the characters - Assassin, Tank and Warrior I'd like to figure out the values so that the Assassin is guaranteed to defeat the Tank, meanwhile, the Tank is guaranteed t...

 
11:04 PM
Where is the code you currently have? And why aren't you asking this on Code Review? — Scott Hunter 14 secs ago
"Any tips to make this happen while using simple looking code?" - this could be written several different ways. No one here wants to just write it for you. Give us your current code and we could make some recommendations, but in general if you're trying to optimize your code Code Review is a better place. — h0r53 56 secs ago
what is code review? I'm new to to coding and to this website so please excuse me — Paul Atreidis 58 secs ago
 
11:53 PM
0
Q: Rust Locker Problem Number Theory

amicharskiThe Locker Problem is as followed: Twenty bored students take turns walking down a hall that contains a row of closed lockers, numbered 1 to 20. The first student opens all the lockers; the second student closes all the lockers numbered 2, 4, 6, 8, 10, 12, 14, 16, 18, 20; the third student opera...

 

« first day (2939 days earlier)      last day (1079 days later) »