Welcome to Software Development on Codidact!
Will you help us build our independent community of developers helping developers? We're small and trying to grow. We welcome questions about all aspects of software development, from design to code to QA and more. Got questions? Got answers? Got code you'd like someone to review? Please join us.
Search
tl;dr Just use a POST. There's likely literally no reason not to in your situation. REST is not a standard. Being RESTful in and of itself is not a virtue. I strongly suspect that your current...
I'm able to access a, since b is below a on the stack. No, it's not! You have no guarantee in what order the compiler allocates temporary variables on the stack, and even whether it does so at al...
Notice You'll need to backpedal some! Read the answer by @r~~ above, but I expect you need some hints. This reads as either a selfstudy or schooling exercise task, so I'll stick to review + hints...
NIST Special Publication 800-63 says that "strong" password requirements are not only useless but counterproductive. They recommend only a minimum length requirement and a small blacklist of common...
What are the differences between git apply and git am commands? Both seem to be used for applying patches to repositories. When should one be used over the other?
Each of them has an analog to another Git command. But instead of objects in the repository, these take text file(s) created either by you or someone else. git apply Think of this as Applying a g...
I read posts (e.g., 1, 2, 3) that recommend triggering a CI build process by pushing an empty git commit. I don't understand how this is a good idea as the commit history will be peppered with mea...
Say I've made a bunch of changes to a file and would like to split those changes into two or more commits. Normal git add however stages the whole file in one go. So how to add only some of the ch...
The other answer already provides the more straighforward solution (push with --delete option). But there's an older syntax that also works: git push <remote-name> :<branch-name> N...
Terminology "Mutable default argument" means exactly what the individual words would suggest: it's an argument which is supplied as the default value for that parameter, which also is mutable. To ...
How to move the main branch back to an earlier commit in git?
With git reset, but first, you may want to save the current state in another branch: $ git switch main $ git branch backup-of-main Now the (perhaps messed up) state is safely stored in branch ...
Arrays in Java are created with a fixed length, which cannot be changed in its lifetime. The only way to really change the length of the array is to create a new array with the intended length and ...
Hi and welcome to the site. :) I think the idea of a canonical like the one you linked is great. A lot of newbies have too little understanding of their topic to identify common patterns. So they ...
You want git worktree: https://git-scm.com/docs/git-worktree. The idea is that you can have multiple branches of the same repository checked out to different directories, but they're still the "sa...
How do I add functionality to the back button in Android without reimplementing the back button entirely? Prior to last year, I would just call onBackPressed() and then simply override it: overri...
There is basically only one reason not to use static functions in C, as opposed to functions with global scope. That's if you want to access the function from outside the module. Otherwise, if th...
How to verify if a year is leap? Given a numeric value (such as 2023) or some object that represents a date (such as Date, Calendar, LocalDate, etc), how can I do it?
I agree with Dirk Herrmann's answer about this: What if a question is beginner level? I would say: Someone should answer it. Some of the beginner level questions on stackoverflow have rece...
Your grep invocation will first search for files which contain foo and print a list of the lines from each which contain the word foo; the second grep invocation will take this list and filter it d...
See this comment: https://forum.qt.io/topic/60546/qpushbutton-default-windows-style-sheet#3 Stylesheets are a totally different beasts. The default native drawing doesn't use stylesheets. They ...
fn x [] = [] means that if the second argument to fn is an empty list, return an empty list. fn x (True:ys) = x : fn x ys means that if the second argument to fn starts with True, return a list th...
I was chatting with somebody who's involved with a proposal on SE for a site about language design and who is interested in other options too. Some sample questions: What are the tradeoffs b...
Python documentation suggests that you can simply add other parameters when raising the Exception and retrieve them using args: Code try: raise Exception('spam', 'eggs') except Exception as in...
In a Qt application I have nothing more than a window with a button as its direct child. I set its background color and all is fine: Window::Window(QWidget *parent) : QWidget(parent) { but...