« first day (1905 days earlier)      last day (2118 days later) » 

12:00 AM
RELOAD! There are 5446 unanswered questions (89.9607% answered)
 
12:25 AM
0
Q: Another way to accept txt file DepthFirstPaths.Java

Walter A. Cueva DiazI can't seem to figure out why is it that I get a the red line under Graph(in). Any suggestions or modification to the code are welcome. See screenshot below, line 85. I would like to be able to read an external txt file. Thank you so much https://ufile.io/y1dh8 ----> input file I am using ...

 
12:41 AM
-1
Q: Bank Account Tester, A bank account has a balance that can be changed with withdraw or deposit.(constructs a bank account with zero balance)

HeatherCreate a project named BankAccountTester. Create a class named BankAccount. A bank account has fields for a balance. The bank account balance should be initialized to 0. The bank account class should include a deposit which adds an amount passed to it to the balance and a withdraw which subtracts...

 
 
1 hour later…
1:43 AM
Hi
@200_success Can you guide me on testing this code?
4
Q: Overlapped - first two tokens

overexchangeProblem Two folders having files with name Afile. Files has 3 tokens, where first token is dotted decimal, second is hexcode and third token is a multi-line token(less important for this query). Third token is optional. First token is also called trap, second token is called event code, technic...

 
2:02 AM
I'm happy to review your code when time permits. However, please don't turn me into your personal tutor.
5
 
2:18 AM
Worked for a Medical Transportation company that had a contract with Medicaid.

One of their many rules was that you could not provide any assistance to the patient INSIDE of their house.

One elderly lady had an old house with a very small foyer that you had to climb three steps to get to the main floor. The only other entrance was around back and up two and a half flights of rickety steps to an old deck that opened into a bedroom.

Upstairs. She's in a wheelchair.

Common sense says take her in the front door, up three stairs and she's home on the level she lives on.
 
2:35 AM
0
Q: Hello World Android App

AnthonyWestonI wrote a simple Hello World app for Android that does the following: Accepts a name Allows the user to select a language Opens a new activity that greets the user in the language selected by the user The things I'm looking feedback on are: General coding style Use of Android specific codin...

 
2:51 AM
1
Q: better model architecture in django

PriyankaI am developing a project with various tables so i can have better understanding of model relation by communicating with the experts. Can anyone look at my code, if i have designed my models based on the following conditions or not, please? Only the relation in the model. Users There are 3 type...

 
 
1 hour later…
3:57 AM
"You want to associate the changes to the file to a work item, not the file itself." Most of the time yes, but not all the time. You may want to link a workitem to a code file to remember to research it later, or to record what looks like a bug but you may not have time to look into it during the current task. The code review is close but is still linking to a shelfset. — StingyJack 1 min ago
 
 
2 hours later…
5:36 AM
I think you need to post it at codereview codereview.stackexchange.comMathew Magante 42 secs ago
 
6:08 AM
"That code is a weird mix of C++ and pointlessly-low-level/opaque code." There is an important lesson in there, @RakeshKarandikar . Online judges rarely reward for code that passes a code review, but good code is what get you hired and keeps you hired. Learn what you can from competition sites, but also read up on and practice good software engineering. — user4581301 9 secs ago
 
0
Q: Creating my own netflix in c # What you think?

Damian Sire Hi, the english not is my native lenguage, sorry my bad syntax. I want to make my own netflix in c # (Without using sql, only using dynamic memory). (Not the part of watching videos) I thought about this class diagram. What do you think? In my main program I have a list with all the existing ...

 
6:42 AM
-1
Q: AJAX+Laravel: after I successfully do process in AJAX, other functions are not working

muhammad adityaSorry my english not good :) I have problem with AJAX success in Laravel, after I successfully do process in AJAX, other functions are not working. Like the picture below, I like status or comment, function of collapse button and favorite button does not work. In AJAX success I use $("#divwra...

 
Monking
 
7:31 AM
0
Q: Code Comments for Python Project

iking15Please give me some pointers on how can I better code below project with Python 2.7. Any Improvements or Suggestions or Comments will be appreciated. import json import urllib urls = ["https://data.calgary.ca/resource/kqmd-3dsq.json","https://data.calgary.ca/resource/4wni-k3sg.json"] print " \n...

 
8:04 AM
-1
Q: VirtualBox Wifi Adapter not showing

Carl ClintonMy Wireless Adapter is not showing in Virtual. I am not understanding what is the problem! Help!! See these pictures Wireless Adapter Settings

 
8:37 AM
-1
Q: Function to skip meta data in a .csv file using Python

Ajgar DevI have a functioning code to skip the meta data in a .csv file using Python. However, I cannot understand what this part of the code is doing: else: if not col: continue #No columns found yet else: i+=1 #Last column found break The whole code is as follows: de...

 
I'm voting to close this question as off-topic because this question is about working code. Questions on how do I make this more efficient belong on StackExchange site Code ReviewDavid C. Rankin 59 secs ago
 
9:25 AM
-1
Q: Udacity's Python Stack implementation with Linked List, delete_first method doesn't detach element completely?

hockeymonkey33I'm looking here: Udacity_link (please push Start Quiz on the above page) at this method: def delete_first(self): if self.head: deleted_element = self.head temp = deleted_element.next self.head = temp return deleted_element else: ...

 
9:42 AM
1
Q: Is this collision detection OK? Will it run at acceptable speed?

DarkWiiPlayerAfter implementing SAT (separating axis theorem) and not being happy with it only working on stationary shapes, this in theory allowing for fast objects to glitch through others, I came up with this approach to detect collisions between moving objects. Algorithm explained The idea is quite sim...

 
 
1 hour later…
11:22 AM
I'm voting to close this question as off-topic because it is asking for a code review (and this thus too broad / opinion based). It could probably be adjusted to be on topic for the code review stackexchange. — Quentin 58 secs ago
CodeReview is a better place to ask improvement though. — Marcus.Aurelianus 1 min ago
 
11:37 AM
0
Q: How to avoid duplication of code in my IF-ELSE code?

SunManI have written this function ( in c++ ) void printResults(double a, double b, char c) { double r; if (c=='+') { r = a + b; } else if (c == '-') { r = a - b; } else if (c == '*') { r = a * b; } else if (c == '/') { r...

 
 
1 hour later…
12:42 PM
0
Q: Connecting 2 databases: one for admins and one for customers

Kar19I am working with 2 databases. One for admins ('backoffice') and one for users. Account managers: Use the 'backoffice' database to manage customer accounts. Customers: Whenever a users connects and inserts his username password and company name, the code must connect to the backoffice datab...

 
 
2 hours later…
2:19 PM
-1
Q: python tic_tac_toe

szeI am new to python and I try to challenge myself by writing a tic tac toe.My code cant run until the end.The error is( File "C:\Users\win7\Desktop\python apps\tic_tac_toe.py", line 30, in p2 if board[x]=="O" or board[x]=="X": TypeError: list indices must be integers or slices, not NoneType ) Plea...

 
2:36 PM
0
Q: Noughts and crosses game for 2 players in Python 2.7

OrGoThis is my first program in Python that I have coded and I am relatively happy with how it turned out. I would like to know how I could make my code shorter and more efficient. def one_round(player): #Distinguish player 1 from player 2 if player == "p1": p = "Player 1" elif p...

 
 
1 hour later…
3:41 PM
-1
Q: HackerRank Lists problem using Python 3

geeky_sohamThis is my code i wrote for the HackerRank lists problem(The problem )using Python 3. I'm not getting the desired output. Any edits to my solution to get the desired output ?? if __name__ == '__main__': data = [] N = int(input()) comm = [] for i in range(N): ele = input() ele = ele.split...

 
Did you try codereview.stackexchange.com ? You may get more feedback. — Michael Doubez 54 secs ago
 
4:15 PM
-4
Q: This problem is killing me

user175525does anybody know or have anybody built a program that solves this?

0
Q: Grouped by First Two Digits of Account_ID of ~240 million rows of Pandas DF

AriefI have 40 csv files, each containing ~6 million rows, and 2 columns. The columns are : account_id and account_balance. The objective is getting the sum of all account_balance grouped by first two digits/chars of account_id. For example : account_id = 00as3dff01234 is in group 00, and the account...

 
4:31 PM
3
Q: Streaming scheduled TV shows according to a CSV playlist

Esben Boye-JacobsenI'm very new to Python, and I've made a small program/script that will allow me to stream specific files at a given time. My idea is that I have a .csv file for each day, with one row for each movie/tv show i want to watch and a cron job that checks every 30 minutes (at :00 and :30). If the job...

1
Q: Debian Firefox Quantum Update Script

iuvbioI wrote a little script to automate upgrading Firefox to a new version under Debian, since I don't want to install it from unstable and the snap version has rendering issues. Any comments are welcome, is there anything I have missed or any potential problems? #!/bin/bash # firefox_upgrade - pr...

 
 
2 hours later…
6:11 PM
0
Q: Simple Event Dispatcher

PeMaCNHere is my very first event dispatcher. I would like to get both, style and code review, as well as some ideas to improve this implementation (new features etc.) I tried to write code in C++17 style as much as possible. IEventDispatcher.h #pragma once #include <map> #include <functional> tem...

-1
Q: word ladder bfs function

OffsetI am trying to solve https://leetcode.com/problems/word-ladder/description/ My approach is to construct a graph of all the words in the dictionary + the starting and ending word. If a BFS gives the shortest path then I can do a BFS on this graph and stop when I reach the end word (in this examp...

0
Q: Efficiently counting rooms from a floorplan

EdwardI was inspired by Calculating the number of rooms in a 2D house and decided to see if I could come up with efficient code to solve the same problem. To recap, the problem (from here) is this: You are given a map of a building, and your task is to count the number of rooms. The size of the m...

 
6:45 PM
possible answer invalidation by Edward on question by Edward: codereview.stackexchange.com/posts/200051/revisions
 
Hello @200_success! Sorry about the answer invalidation -- I hadn't noticed there was already an answer.
Now we have two versions of the code -- a correct one and an almost correct one.
Should I delete the old one? Or just leave them both?
 
Well, by the rules, you would have to ask a follow-up question.
You might want to wait a while first, though.
My first impression, on seeing that problem, was that it should be an instance of .
 
I've already asked the follow-up question, since I didn't want to waste people's time with known-incorrect code.
 
I suggest putting a big referral link at the top of the original question.
 
Good idea. I'll do that. Thanks.
@200_success You might be right. I wasn't familiar with that algorithm, so I'll study it.
 
7:00 PM
0
Q: Efficiently counting rooms from a floorplan (version 2)

EdwardThis is version 2 of Efficiently counting rooms from a floorplan. I had accidentally pasted in the wrong version of the code. I was inspired by Calculating the number of rooms in a 2D house and decided to see if I could come up with efficient code to solve the same problem. To recap, the probl...

 
 
1 hour later…
8:04 PM
-1
Q: Java GUI Construction: An error on the Exit Button Listener

Eduardo GonzalezSo far, I have managed to design the backbone of a Java GUI application that calculates a fast food order. Here are the following codes for each of the four segments: The greeting panel import javax.swing.*; public class BBH_GreetingPanel extends JPanel { private JLabel greeting; public BBH_G...

 
8:45 PM
ThrowEvent is odd terminology, usually you'd call it RaiseEvent. Your getNewID method is not thread safe, you may end up reusing an Id. Try the Interlocked class to get around that. I highly recommend looking into c# naming conventions. As you mention Unity, I know they may differ there, but double underscores is very odd (and hard on the eyes), most especially when used for local variables and parameters. At the very least be consistent. Also, as you have "a working solution", this question is probably a better fit for codereview.stackexchange. — pinkfloydx33 44 secs ago
This question would probably be better served on codereview.stackexchange.com — pinkfloydx33 43 secs ago
 
0
Q: Getting angle between all points in array

pydudeI have got some code that calculates the angle between all of the points in an array. It works, but it is quite slow. This is because it has complexity O(n^2). It has to loop through the array and apply the angle function to every combination of points. import math import random def angle(pos1,p...

 
 
1 hour later…
9:59 PM
-1
Q: python bank user creator

mohammad rezazadehI'm just learning Python. My teacher gave me a practice that I'm confused. Please help me ask the question: Inside this exercise, we want to develop the system we wrote in the classroom, but we do not want it anymore Write a system, we want to write a banking system! So we have 3 types of users w...

-1
Q: malloc() and free() using sbrk()

Prateek PisatFor an assignment, I need to implement my own version of malloc() and free(). However, the code that I wrote fails a particular stress test using which our code will be graded and I can't figure out why. Can someone please review the code to help me identify my mistakes. My implementation is hea...

 
10:17 PM
"So, I decided to post it here to discuss it with you. - This isn't the place to discuss since it tends to fill up the comments area. I (for one) don't know what it is that you're asking or what the real question's about. If your code works as you placed comments in each of them and feel that you may still be open to injection and asking others if it's ok or not, then the post should be moved into a chatroom somewhere and/or posted in code review. — Funk Forty Niner 38 secs ago
 
10:31 PM
0
Q: Swiftly count rooms in a floor plan

Martin RInspired by recent questions about counting the rooms in a floor plan (1, 2, 3), here is my attempt to solve the problem with a Swift program. The problem (from “Counting Rooms” on CSES) is: You are given a map of a building, and your task is to count the number of rooms. The size of the...

 
11:15 PM
possible answer invalidation by kevinf on question by kevinf: codereview.stackexchange.com/posts/156050/revisions
 
11:49 PM
You may have better luck here: codereview.stackexchange.comsniperd 9 secs ago
 

« first day (1905 days earlier)      last day (2118 days later) »