Code Review Weekly Newsletter

Code Review newsletter

Top new questions this week:

Operations to a bank account

I am a new .NET/C# developer and one issue bugs me ever since I've wrote code the first time. How can I improve this code? Program.cs: class Program { static void Main(string[] args) ...

c# finance  
asked by Alexandru Mitu 13 votes
answered by Rotem 11 votes

A game of nodes and pixels

I'm still pretty new to JavaScript. I'm making a game to get a better understanding. Although it's working exactly how I want it to right now, the code could definitely be less repetitive and more ...

javascript jquery game html css  
asked by Chris_topher 11 votes
answered by Spike 16 votes

Listing human-readable enums

I'm trying to do some util class to operate on enums - convert Enums to its special strings representation via interface method. String stored in enum constructors. public enum StatusEnum implements ...

java performance reflection  
asked by Alex Silkovsky 10 votes
answered by Simon Forsberg 9 votes

JavaScript function to generate tree object from flat object

The following function takes an object of items in the format of { 'complex-key': 'value', // Repeat } where complex-key is a key delimited by dots, and returns an object in the form of a tree, ...

asked by Madara Uchiha 9 votes
answered by Benjamin Gruenbaum 8 votes

Musical Fizzbuzz

I wrote some code using ChucK : Strongly-timed, Concurrent, and On-the-fly Music Programming Language and would like a review. I broke down the logic into a number of classes, all of which are shown ...

fizzbuzz audio music chuck  
asked by Phrancis 8 votes

ROT47 Implementation

ROT13 ("rotate by 13 places", sometimes hyphenated ROT-13) is a simple letter substitution cipher that replaces a letter with the letter 13 letters after it in the alphabet. ROT13 is a special case ...

c++ caesar-cipher  
asked by Aleph0 8 votes
answered by Mat 12 votes

An alarm application in Java

I have programmed this alarm application in Java using JavaFX for the GUI. I'd like these questions covered in the review: Is my code efficient? Can it be shortened? Are there any flaws in my code? ...

java gui javafx  
asked by Hassan Althaf 8 votes
answered by toto2 5 votes

Greatest hits from previous weeks:

A simple Dice Roll game

This is the code for a simple dice roll. Any opinions for this are welcome and any suggestions to improve it would be appreciated. Is there a more efficient algorithm to generate random numbers in ...

c++ beginner game random dice  
asked by Arpit Agrawal 8 votes
answered by Loki Astari 13 votes

Unit of Work and Repository with Entity Framework 6

Based on the reply of this question I have created the following code. I need to check whether it's good or not. Here is my entity class: public class Employee { public int Id { get; set; } ...

c# entity-framework  
asked by Jalpesh Vadgama 20 votes
answered by Mat's Mug 18 votes

Can you answer these?

Obtaining employees and their roles, and vice versa

I am using the following query to obtain a employee with his information, and get all his related roles. The query underneath works fine when we check only 1 location taking only about 0.002seconds to ...

performance mysql  
asked by MX D 3 votes

Converting partial XML (Node List) to a String

I have a need to extract a part of XML tree (everything under root) and convert it to a string. (The result string will be later pasted inside XSL-FO XSLT file.) The above functionality is a part of ...

java xml dom xpath  
asked by PM 77-1 3 votes

Counting duplicate tags in a string of many tags

I have a photo list page where each photo has multiple tags (as spaced words). I'm trying to display most of the tags on the page after: Removing duplicate tags Sorting tags by having most occurring ...

asked by Yeti 5 votes
Subscribe to more Stack Exchange newsletters

Unsubscribe from this newsletter or change your email preferences by visiting your subscriptions page on

Questions? Comments? Let us know on our feedback site. If you no longer want to receive mail from Stack Exchange, unsubscribe from all emails.

Stack Exchange, Inc. 110 William St, 28th Floor, NY NY 10038 <3