« first day (3566 days earlier)      last day (48 days later) » 

12:08 AM
REFRESH! There are 7402 unanswered questions (90.3292 answered)
@SᴀᴍOnᴇᴌᴀ I think the question is off-topic, OP states they are presenting example code.
4 hours later…
3:44 AM
Q: Trying to print following pattern issue while trying to print reverse numbers

RamakrishnaExpected Pattern : * 1 * 1 2 1 * 1 2 3 2 1 * Program code : for (int rows = 0; rows < n; rows++) { for (int col = 0; col < 2 * rows + 1; col++) { if (col == 0 || col == 2 * rows) { Console.Write("* "); } else { Console.Write(col + " "); } } Console.WriteLine(); } Program Output :

2 hours later…
6:39 AM
There are linter rules that warn you if you don't await an async function (or a function that returns a Promise), but I can't find any that can analyze all of your code to check if you don't need to have a function be async. I've never ran into this issue myself, this should be able to be caught in code reviews and tests. — Samathingamajig 11 secs ago
2 hours later…
8:42 AM
@pacmaninbw There's a difference between sample and example.
8:55 AM
Your question is offtopic at StackOverflow. You should post it at codereview.stackexchange.comNikolai Shevchenko 13 secs ago
If your code is working as intended but you're only looking for improvements or a review, then you might be better off here: codereview.stackexchange.comQBrute just now
1 hour later…
10:05 AM
Q: This hangman game uses a secret word which the user input

ANTONIO ALTAVILLAI recently started learning programming and in particular Java. I wrote this small hangman game which takes the input for the scecret word from the user. It all works as intended but I would like to know ways to optimize or improve this code (taking into account that the imput must be taken fromt...

2 hours later…
11:46 AM
Q: What are the possible improvements for this Bootstrap block markup?

Rusurano<style> .card-custom { width: 400px; } </style> ... <div class="card-custom rounded-2 shadow-sm d-flex flex-column"> <img src="https://i.imgur.com/wNabyl4.jpg" class="card-img-top rounded-0" alt="Hello World" /> <div class="px-3 py-3 d-flex flex-column justify-content-between gap...

12:11 PM
Q: looking for a better way to ship dependencies (dynamic libraries) with an executable build under Mac OS with Crystal-lang

Serge HulneI am looking for a way to ship dependencies (dynamic libraries) with an executable build under Mac OS with Crystal-lang, is there a way to improve on: It seems to works, but it is a bit of a hack. # The name of the executable app=$1 # Create a directory to hold the app and dependencies mkdir -p "

1 hour later…
1:17 PM
If this is working code then you probably want codereview.stackexchange.com for feedback etc. — Paul R 7 secs ago
1:29 PM
2 hours later…
3:34 PM
Q: Vue.js - Sierpinski Triangle

DelfinoBelow is a Vue app I wrote to draw a Sierpinski Triangle given n iterations, which can be incremented/decremented via a HTML input control. I was wondering if there were any ways this code could be optimized. Thank you! HTML: <div id='app'> <input type='number' v-model='n' min='0' max='10' /> <...

3:59 PM
Q: Laravel Event Filtering Controller

Nifty MatrixSo I am currently writing a function in laravel that handles URL parameter filters. How the code works: So we have the following two URL parameters: timeframe and category an URL would look like this: /events?timeframe=3&category=6 but it can also look like this /events?timeframe=0&category=0 t...

4:09 PM
As a point-of-style (opinionated), if this code were submitted to me for code review I'd say to get rid of the out-parameter and instead have a return result. Even if that return result has to also have that bool, making it tuple<bool, optional<vector<int>>> or perhaps the Boost result<vector<int>, error_code>. — Eljay 11 secs ago
4:49 PM
Q: Bruteforce proof of an arithmetic expansion scheme expression in array lists (Java)

coderoddeGiven a list of, say, integers, one way to implement such a list is to rely on an array under the hood. When we are adding elements to the array list, we might need to make the internal array larger. Here, we have at least two array expansion schemes: (Arithmetic scheme) Expand the array by a fi...

5:02 PM
1 hour later…
6:05 PM
Q: Rust Book Chapter 8 - Text interface for employee management

mrchocoborider Using a hash map and vectors, create a text interface to allow a user to add employee names to a department in a company. For example, “Add Sally to Engineering” or “Add Amir to Sales.” Then let the user retrieve a list of all people in a department or all people in the company by department, so...

6:30 PM
ot: a = nullptr; in the destructor is pointless. Imho it must be removed. I would not let it pass a code review. — 463035818_is_not_a_number 28 secs ago
1 hour later…
7:40 PM
If what you have is working code and you are looking for feedback on it, Code Review would be a better fit. If what you have is not working in some way, please clarify the problem. — David 19 secs ago
1 hour later…
8:58 PM
Also, you're probably better to take this to: CODE REVIEW as that stack is specifically focused on optimizing code that already runs. — Cameron Critchlow 7 secs ago
9:44 PM
Thanks! I'm going to try to play around with the array idea you suggest and see how that works. I also didn't know about the code review, so I'll repost there in the mean time! — love2learn 45 secs ago
Q: Sub that finds Rows with same ID in Col A, then Concatenates to merge values in Col C into single cell with line break deliminater

love2learnI have a VBA that takes all the rows with the same ID in Column 1 and concatenates the data in Column 3 to a single cell with line breaks. The code then deletes the old rows. The code works, but takes 10+ seconds to run. I have about 3-4k rows of data but I was hoping this could run much faster. ...

@Duga I was a little to slow.
@pacmaninbw at least the title was changed :)
1 hour later…
10:58 PM
Hi Mohsen, questions like is this implementation correct? are generally not what is accepted as a valid post on stackoverflow. If you're seeking code review, you might want to head over to codereview.stackexchange.comBijay Regmi 11 secs ago

« first day (3566 days earlier)      last day (48 days later) »