Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options not deleted user 133688

Add this tag to your question to indicate that you are new to the language of your code. This will often be taken into consideration by reviewers when assessing your code.

2 votes

Prime number finder in bash

You say: "This code works, but I'm sure it's far from optimal. I'd like any and all recommendations." AND "And I know better algorithms exist, but I wanted to keep it simple." Unfortunately, these t …
klutt's user avatar
  • 903
5 votes
Accepted

TicTacToe classic in C

malloc I start with one of the most common ones. Instead of char *board = malloc(sizeof(char) * BOARD_SIZE) write char *board = malloc(sizeof(*board) * BOARD_SIZE). If you decide to change the type i …
klutt's user avatar
  • 903
6 votes
Accepted

Determining whether a provided credit card number is valid according to Luhn’s algorithm

First thing I think of is that you have a pretty long main. You should split the code in more functions. Your code could look like this: long long readCardnumber(); bool validateChecksum(long long ca …
klutt's user avatar
  • 903
0 votes

Read numbers between 1 and 5, then print the minimum and maximum

Since this seems like the kind of tasks you get in the very beginning of introduction programming courses I don't really see the need for a code review at this stage. But since you asked, it seems a …
klutt's user avatar
  • 903