« first day (682 days earlier)      last day (3342 days later) » 

3:04 PM
omg, 3rd party using CORS + Cookies
guess what? it doesn't work
I need a desk to smack my keyboard/face on
Cookie-based authentication + CORS, FML
 
Wow Captain Obvious...
 
is there something about a linkbutton with a response.redirect that doesn't work in IE10?
NM. there is something else going on with this crappy code..... what is up with @CaptainObvious?
 
Yeah. IE10. Just IE.....
 
did we just get some cool changes for CodeReview?
 
~confused
 
3:15 PM
Oh man, new Stack Exchange beta site layout looks weird.
 
oh ... front-page design...
 
it looks like the CSS changed for our site.
 
Some wall-o-code triple barrels...
 
The changes that were being piloted on MSE just went live?
 
remember summaries?
they're gone
 
3:16 PM
NOOooo
 
am i missing something? CR looks the sam eto me
 
169
Q: Let’s improve our site navigation

SklivvzA.k.a. the 2015 Questions to Answer Refactoring Konversion (QuARK) A.k.a. the great cheese move of 2015. TL:DR; we are looking to change the navigation of the question lists on the site. We are not looking to remove any functionality or break any existing link. This is not final. We’re taking...

@DanPantry compare this here with this here
 
oh thats a difference
 
also live on MSO AFAICT
 
<rant>
Here's a tip for anybody trying to hire. Tell people what technologies you expect them to know. Don't waste everybody's time by keeping it a big secret.
5
</rant>
 
3:19 PM
@RubberDuck So true.
 
> Thanks, but I'm not going to waste anybody's time that way.
If they can't talk about what tech they expect an applicant to be familiar with, they're not the kind of company I want to work for.

Good luck, and please keep me in mind if you come across anything else.
 
1
Q: Implementing merge sort with mutually recursive methods

fuduProbably this has been asked before but i was hoping to improve the efficiency of my code below. It is an implementation of merge sort using two mutually recursive methods, the thing is that the code was supposed to function better than the usual merge sort function but it is not doing that. I wa...

 
LOL. I can't move @nhgrif. If I could I'd apply, but I won't waste your time either buddy.
 
I would be tempted to apply if I wasn't llocked into a 1y contract at my new place to rent
;p
oh and i was british
that might be a roadblock too
 
3:22 PM
the site that I am working on is being a pain in the Arse! some of the links don't work in IE but they work in Chrome and textboxes are different. the site works fine when I debug...I hate this website and application
 
@Malachi I have spent the past 5 hours trying to get cookie based authentication working with CORS
Never mind the fact that angular lends itself to token based authentication
3rd parties are stupid
 
lucky you guys... at least you don't have to restart tomcat every time you changed a single LoC
 
@Vogel612 if I hadn't split up the projects the 3rd party gave us to two different assemblies i would have to restart IIS
 
@DanPantry when I searched CORS this came up --> plus.google.com/+AndrewMaxwell01/posts/6qwPMVRbsbd
 
@Malachi sounds about right......
CORS is a bitch, sadly it keeps the web safe
It's not actually THAT terrible, as long as you don't, you know, use cookie based authentication with it
froths at mouth
2
at least my pain is funny to someone lmao
 
3:25 PM
better that than storing all Data you ever handle in your application in a Map<String, Object>
on the Java side
because, you know: Classes are for noobs
 
@Vogel612 you win
 
well at least it's 90% Property-based constants...
and not just hardcoded magic Strings all over the place.
 
magic strings you say
        this.LoginAsDemo = () => this.Login('demo@foo.co.uk', 'demo@foo.co.uk', true);
Yes, this is in development code, put there by the 3rd party
|:
 
wait wut?
 
I'm voting to close this question as off-topic because this belongs on codereview.se. — BalusC 1 min ago
 
3:29 PM
 if(data === 'null')
just another gem
 
This is not really code review. It does not belong on CR. — Dan Pantry 1 min ago
 
@DanPantry just for the Record.. BalusC is the JSF person on Stackoverflow.
 
@Vogel612 link
@BalusC no it doesn't. The code given here is not "real code" as Codereview.SE requires. Code submitted to codereview is supposed to be as close as possible to the actual productive code (and not a minimal example demonstrating the design) For more information, please read the help center (and if you got some more spare time: meta.stackoverflow.com/questions/253975/be-careful-when-recommending-code-review‌​-to-askers) Thank you! — Vogel612 48 secs ago
 
JSF?
 
Java Server Faces
 
3:32 PM
in english
oh.
the guy who has enough expertise to answer that question
 
that thing that allows you to make html from java
 
but doesnt
 
well... yes
 
@BalusC no it doesn't. The code given here is not "real code" as Codereview.SE requires. Code submitted to codereview is supposed to be as close as possible to the actual productive code (and not a minimal example demonstrating the design) For more information, please read the help center (and if you got some more spare time: meta.stackoverflow.com/questions/253975/be-careful-when-recommending-code-review‌​-to-askers) Thank you! — Vogel612 1 min ago
 
If not then I don't know why it's relevant ;-; sorry I am a bit dull atm
 
3:33 PM
because OP doesn't seem to listen anyways
> [..] however people say it is a bad idea. But have no specific reason for it.
If I were in his position, I'd not answer either, because OP either won't give a damn (and then my time was wasted) or he'd start to argue, which would waste even more time
 
0
Q: Passing an EJB as a paramater. Bad idea?

AnkitI am developing a new application and was wondering whether passing EJBs as method parameters is a bad idea or not. I have my managedBean (MB1) in which i injected an EJB. Now I am calling a static method from (MB1), in which i am passing the EJB. The static method then can use that EJB to fetch...

 
It was moved here anyway.
 
no it wasn't
that's a cross-post because OP obviously is too retarded to read
 
Well, it was posted here.
 
And now we deal with it. What about it?
 
3:38 PM
3 close votes so far
can we make it a 4th
 
@BalusC i have posted the question on codeReview too. The question belongs more to design aspect and good programming practices. I have faced no problems yet using this approach, however concerned about is it a good practice or not. — Ankit 38 secs ago
 
Nothing, except it needs dealing with.
 
well then that's it, right? ;)
 
dusts hands
good work toys
back to work
 
toys??
 
3:41 PM
4th vote posted by someone.
 
toy story reference, eh? also you might want to add http:// before that
 
it's a simpsons reference
:p
 
Did SE roll out a new design for beta sites?
 
@DanPantry s/t/b
 
3:42 PM
@RubberDuck wat
 
Everything looks a bit different.
 
@Hosch250 ya.
 
s/toys/boys
 
okay got your point. I will edit the question giving actual code and ask it on code review. — Ankit 1 min ago
 
It was intentional @RubberDuck
 
3:43 PM
LOL. Oh.... my bad
 
There, closed.
 
@RubberDuck reference
...
fk it
 
he's a witch
burn him
 
^^ just the url, and nothing but the URL
well... nothing but maybe a reply ;)
also... having developed half a chatbot for SE/SO/MSE-chat helped a little ;)
2
 
4:01 PM
Hmm... CR looks different...
 
you're like... the fifth to state that in the last 2 hours
 
Well, its the first time I noticed...
 
I just reduced the size of some of my files by 33% by creating an interface that is the same size as one of the 33%'s.
There is still some duplicated code, though, that I'm not sure how to remove.
Going to post a question.
 
@BalusC posted the same on codereview, hope now it does not violates the rules of stack exchange. :) — Ankit 1 min ago
 
On topic now?
-3
Q: Passing an EJB as a paramater. Bad idea?

AnkitI am developing a new application and was wondering whether passing EJBs as method parameters is a bad idea or not. Concept Explanation: I have my managedBean (MB1) in which i injected an EJB. Now I am calling a static method from (MB1), in which i am passing the EJB. The static method then ca...

He has the working implementation in there now.
At least he says he does.
 
4:08 PM
0
Q: Implementation of Hangman using Java

Calculus5000I’ve been getting used to Java and I’ve written a simple hangman game using event-driven programming in Java 8. Please let me know of any improvements regarding the readability and design of the program. Main - used to start the game package Hangman; public class Main { public static void ...

0
Q: add (register) and login (select) in mysql using the OTL library

morbidCodeThis is an extremely simple login/register system using the OTL library and mysql using the mysql ODBC connector. Thing is, what I'm trying to do is so simple that my current code might be too long for such a simple task. // table "user" with fields username and password and possibly other field...

 
Looks borderline and might need some cleaning, but ya..
It seems okay
 
4:20 PM
0
Q: TextField Validation for Teleport Feature in Game

bazolaI've implemented a teleport feature for my game and I would like some feedback on the way that I validate the user input. I am using the libGDX library. When the player clicks the Teleport Menu button, a menu will pop up that has two TextFields pre-populated with zeros. The user can click the T...

 
higlight potential problem 1 hour and a half before work closes up shop
direct superior in meeting until end of work, other superior goes home
I have nothing else to work on
????
 
profit, maybe?
or... refactor some more crap code?
 
I've broken the project enough as it is
I think I'll learn about token based authentication because I a m going to have to implement it anyway
 
4:38 PM
The old SE design was better.
Anyway, seeing the Captain is a bit slow today:
 
meh,
 
0
Q: Abstracted Interface for Settings

Hosch250I just learned about the beauties and wonders of interfaces. And, I realized how I could fix some code that has been bothering me because of its duplication. This is my ISettingsProvider and SettingChangedEventArgs class, which are in the same file: public class SettingChangedEventArgs : Event...

 
@Hosch250 don't forget the abstract part. You wouldn't want someone creating a new instance of the base class.
 
@RubberDuck Yeah, just researching the abstract keyword.
 
There's also an example in the rubberduck repo
I've gotta go.
 
4:42 PM
OK.
 
3
Q: Abstracted Interface for Settings

Hosch250I just learned about the beauties and wonders of interfaces. And, I realized how I could fix some code that has been bothering me because of its duplication. This is my ISettingsProvider and SettingChangedEventArgs class, which are in the same file: public class SettingChangedEventArgs : Event...

 
I don't like abstract
 
If you can get your code to work then questions about cleaning it up and improving the style are much better suited for the codereview site: codereview.stackexchange.comshuttle87 1 min ago
 
0
Q: Efficient use of LINQ - Indexing

Mason11987I have a Class with a List of objects, and those objects contain a list which has lists to objects in the first class, and I'm trying to quickly index them. Simplified: class Person { public IEnumberable<HistoricalEvent> Events { get { return World.Historical...

 
Something looks different on the front page...
 
4:52 PM
@Jamal Yup, everyone is noticing it.
 
Oh, damn. I almost thought I was on SO. Phew.
4
 
@Jamal Lol
 
I then noticed the lack of garbage, and finally figured out I was on CR.
2
 
Next time just look at the URL.
 
0
Q: How to split code into smaller functions

Kris ArmstrongI have an application that works. But in the interest of attempting to understand functions and python better. I am trying to split it out into various functions. I"m stuck on the file_IO function. I'm sure the reason it does not work is because the main part of the application does not understa...

0
Q: jquery checkbox must "delete" an option and viceversa

Antonio CassanoI have this form <input type="checkbox"/> <select > <option value="" selected></option> <option value="volvo">Volvo</option> <option value="saab">Saab</option> </select> If I select an option value (i.e. volvo) and then i click on checkbox i would "delete" option selection. And if i select ch...

0
Q: usage of java 8 streams instead of nested loops

dnano91i'm trying to get more familiar with Java 8 streams as they seem to be very powerful (and shorter). So i rewrote a method to use streams. However I'm not very satisfied with it and would like some suggestions on how to make better use of streams. The code itself has multiple nested loops, so it's...

0
Q: Effectively compare items in the same list

JamesDonnellyI have this code for (GameObject object1 :objects){ for (GameObject object2 : objects){ object1.collisionHandling(object2); } } I need to compare all the items but I obviously don't want to compare each list item with itself; so item ...

 
5:00 PM
What the...
When did CR suddenly get so much questions?
 
@Hosch250 Nah, I really did know I was on CR the whole time. It just surprised me at first, but I'll get used to it (though I'd rather get used to a real graduate design).
 
OK.
 
Reddit AMA with the #stackoverflow/#stackexchange sysadmins is live, come ask anything you want: https://www.reddit.com/r/sysadmin/comments/2zd9lz/we_keep_stack_exchange_stack_overflow_server/
 
5:17 PM
whoa, the design looks different No, I am not going to be the 10th person today to say that!
6
 
too late :]
 
I still haven't seen it... Looks the same on my phone.
 
the only thing I noticed is that favorites highlight in a different color
 
Good thing it is spring break.
I should probably be doing school, but I spent the morning doing the interface thing.
To paraphrase O' Henry, I could lick the guy who invented school.
 
I have a midterm paper to finish, then I have to start on part 1 of my web server project...
 
5:24 PM
0
Q: My version of tree list recursion code

VadimI have found this appearing-to-be famous problem in Stanford tutorial about trees and decided to solve it. My solution appears to work great: #include <iostream> using namespace std; struct num { int n; num* left; num* right; num* next; num* pr...

 
I have a 6-page single-spaced paper to finish, I'm almost halfway done content wise, by April 6th.
And then a few discussions, and I need to get back ahead in case I get sick again...
 
Mine is 8-10 pages, 1.5 spacing (apparently), and due tomorrow night.
 
Uh-oh.
Hopefully you are almost done!
 
I am. I just have one page left. I haven't started on the web server, though. Still a bit intimidated.
 
OK, good luck!
One of my sisters is on a dating website.
3
 
5:27 PM
9 pages at 1.5 spacing is the same as 6 pages single spaced.
Someone should star @Hosch250's message there...
 
They are looking for wives for me (of course there aren't any), and my mom and other sisters are pressuring her to write to guys.
I have a policy that if someone else finds a girl they want me to marry, I will not marry her.
And, I'm not looking for one myself, either.
 
1
Q: Combining CSVs using ruby to match headers

Soviet_JesusI am trying to write a ruby script that will take all of the CSVs in a given directory and map their headers out so that duplicate columns will match up and columns unique to a file will have their own column in the final data file. The following code produces the output I desire, however somethi...

0
Q: parse a list of people to determine who likes someone

MarkI have a data file that looks like this: Friend Name Joe Likes Jill Age 30 Gender Male Friend Name Likes Mark Age 30 Gend...

 
I'm "looking" for one as well, but still no luck. Maybe I just won't meet anyone while I'm still in college.
 
Good luck!
 
Btw... One more vote to rep cap me on Stack Overflow today.
 
5:32 PM
Once I was three points away from rep-capping here.
Didn't make it.
 
@Hosch250 There are so many dating sites though. Which one is it so I know who not to hit on?
 
@JeroenVannevel I'm not sure.
Anyway, they aren't interested in you - you drink.
They don't want drinkers, smokers, or people who like the girls in general.
 
I go out once every 2 months. Way to make me sound like a wifebeater
 
I didn't say you beat your girlfriends.
 
Your sisters don't want men who like girls?
 
5:34 PM
They want one who will be faithful.
 
...
 
I don't think I can handle the large amount of new questions here at CR...
 
@nhgrif Enjoy the rep cap and badge.
 
I already have that badge.
Also, you upvoted a question, not an answer.
 
So? NiceQuestionBadgeCount++;
 
5:38 PM
Oh, you found a one-vote-short post. Thanks.
But I'm still short of rep cap. ;)
 
It says you have 200 rep today.
 
Says 198 for me.
 
you must've downvoted two answers then
 
Funny, says 200 for me.
 
We don't see that
you do
 
5:39 PM
Just refreshed the page.
@nhgrif Did you lose two rep on another site, maybe?
 
Then I can get 2 more rep.
 
That would knock the green bubble down.
It is still saying 200 for me.
Peculiar.
 
It shows you your per site rep. I have +198 on SO and +10 on CR today.
 
OK.
 
I downvoted two people on SO because they were morans.
2
 
5:42 PM
OK, NiceAnswerBadgeCount++;
 
Now it says +208...
 
Hmm, Bing is clever.
 
I thought it capped...
 
I thought the word was "moron"
@nhgrif Nope, answers don't count.
I search "moran", and it returned people in bikinis.
I certainly think people who post pictures of themselves in bikinis on the web are morons.
I also learned that moran is an alternative spelling of moron.
 
0
Q: using methods and constructors to construct a basic calculator in java

RichmahnnAm trying to come up with a simple basic calculator but am supposed to work with the following constructors and methods simpleCalc(); simpleCalc(double op1, double op2); double add(); double add(double op1, double op2); double mult(); double mult(double op1, double op2); double exp(); double exp...

 
0
A: PHP Goutte. Select button without "value" field

juanitoup this answer up this answerup this answer up this answer up this answer

 
@Jamal Huh?
 
6:08 PM
Whoa.
Nasty answer.
 
0
Q: how to create a 10 q maths test, which gives how many correct and wrong you got

bobby dazzlerive got this far can any one show me how to create a maths test which tells the user how many they got correct and how many they got wrong at the end import random for x in range (0,10): A = random.randint(0,100) B = random.randint(0,100) C = 0 D = 0 print "What is", A ,"Plus" ...

 
6:22 PM
If you guys aren't married, you so totally should get on that. My wife just brought me a doughnut & coffee.
 
Nice.
I don't eat doughnuts or drink coffee, though.
I updated my question, BTW.
 
I saw, unfortunately, I'm actually working.
 
OK, no problem.
 
@RubberDuck At work? That's really nice of her
 
@skiwi I work from home... but still!
 
6:27 PM
@RubberDuck I'll first finish school and then get a job. :-) But I wouldn't mind having a doughnut and coffee right now.
 
Om nom nom
 
I'm happy as I made my first ever Neural Network today :)
2
 
I'm happy because I cleaned up some nasty code in my app, I'm sad because I'm doing school, and I'm longing to get out side on this nice spring day and never come back in.
 
My code is a real mess though
 
I just have seven weeks left, but they're gonna be damn challenging. Two projects (one group and one individual), on top of other homework.
 
6:32 PM
1
Q: Non-blocking line-oriented input from several file descriptors

zwolThis is a follow-up to Extracting lines from a bytearray ; I got a pretty good answer to the narrow question I asked there, but was invited to show more of the code in case there was a simpler way to solve the larger problem. So here's my entire module. Note that the use of select.poll instead ...

 
That is too bad.
I like learning, but I HATE school deadlines and being forced to learn things.
I probably learned more doing my interface thing this morning than I will have learned from most of my classes (individually, not combined).
 
Me too, but I need to finish soon so that I can pay off this loan. School is too expensive.
2
 
I hear you.
 
6:47 PM
@Jamal Write some code that someone has to have and then make them pay you for it.
 
A code generator?
 
@Malachi Good idea. I'll watch out for more homework questions on SO.
 
Whoever invents that will be able to buy the US with the cash in their pocket.
 
@Jamal lol
 
Those students will get in trouble.
I'm not sure, but you might get in trouble too.
 
6:52 PM
I was just joking. It is funny when their teacher finds out and posts a non-answer.
 
Have they ever?
That would be funny.
 
I've seen it happen a few times.
 
What happens to the students then?
Does the question get closed?
 
Yes, if it's just a gimmetehcodez question.
 
If it is a good question, the teacher would be a jerk. Otherwise....
Just finished a philosophical discussion on global warming climate change.
 
6:54 PM
There's hardly ever a good homework question on SO, it seems.
 
Nope.
I am thoroughly embarrassed about the quality of my SO questions.
I just deleted a couple answers, and I should probably delete a few questions too, but I don't really want to get banned.
I could probably flag some as duplicate.
Time to take puppy on a walk, see you.
 
7:20 PM
It's been a while since I wrote that and I don't recall the situation I was in at the time. If I were in a code review now and someone wanted to use BigDecimal, I'd go with it. — Tony Ennis 17 secs ago
 
0
Q: Suggestions for improvement - C++ program that recognizes a context-free language

Imraaz RallyThis program(C++) was for a class project. A program that recognizes a given context-free language by implementing a pushdown-automaton (PDA). I documented the code and host it at github as well. The PDA recognizes only the language described. Also, the program passes all test-cases. https://...

 
7:40 PM
Questions like this are probably better suited for codereview.stackexchange.com — Thomas W. 41 secs ago
 
@Duga in a way, correct... but OTOH is a feature-request
@Duga agreed and flagged
 
Does it make sense to have a Tree data structure with only one property? A Root of type TreeNode?
 
0
Q: Anything wrong with my log(n) "sort by value" Map<K, V>?

dwakamI've read so much arguing about "sort by value maps". Well, as a means to learn more Java, I wrote the following log(n) sort by value Map . And, by the way, a real Map , does not allow duplicate keys. Many of the maps I googled ignore that annoying problem: public static void sortByValue_logN() ...

 
@RubberDuck yes.
 
@Vogel612 Thanks. Will post this for review later.
 
7:50 PM
@ThomasW. since this question asks about how something intrinsically changing the behavior of the code could / should be done it's off-topic for Codereview. On the other hand you are somewhat correct in that questions about actually working code which could use a performance tune-up are on-topic at codereview. In this case I'd advise against a codereview question. Instead you might want to edit the question so it can become a great SO question. (I see some potential here). If you want more information, feel free to drop by in codereview chatVogel612 51 secs ago
 
Gd VBA.... writing my own data structures.... grumble grumble grumble
 
@RubberDuck I personally never understood how Trees can be implemented like this:
class Tree<E> {
     private Tree<E> left;
     private Tree<E> right;
     private E value;
}
well it's easier to extract subtrees that way, but meh...
 
i'm sure there's a very smart reason for that, but I think it's probably overkill for what I want to do.
 
Well it depends on what you need ...
sometimes you want to be able to see subtrees as a Tree of their own, sometimes you don't.
 
That's a really good point...
But it would be simple enough to
Dim tree2 As New Tree
Set tree2.Root = tree1.Root.Children(2)
Ya know.... except for the whole not really a copy thing....
 
7:55 PM
correct.
 
I think this will work for my purposes. Still gonna get it reviewed later though.
Need to go plug it into the disaster of a class I built it for.
 
8:11 PM
0
Q: RxJava: Is there a better way to do this than using a Subject?

david.miholaIn my Android app I have a Service that is periodically polling a server for a music playlist XML. For certain occasions I also want to trigger a reload manually. I am using Retrofit for the server communication and my Service exposes an Observable to which some other components of the app can s...

0
Q: k-rotated-shifted array and analysis of code?

Maryam PanahiWe say a k-rotated-shifted array, to an array such that with k rotate can be sorted. Example is : A=[10, 15, 20, 1, 17], with k=2. I propose an algorithm for finding a key like x in this k-rotated-shifted array. at first step, I wrote this code: I found there is one condition must be conside...

0
Q: Philosophers at table

DominicdecocoI'm attempting a take on the dining philosophers problem, in this case philosophers are known as copyists, instead of two chopsticks each copyist has requires a eidograph and a pencil, the classes all need to be contained in the same file, but i cannot see why my code wont print anything? its sup...

 
8:31 PM
Why does the UI look moe like SO's?
 
Because they just rolled it out system wide.
 
I don't think UI can be moe, though...
 
0
Q: Is there too much logic in this controller? Are there pieces that can be migrated to live within the associated models?

j.hwangclass StatsController < ActionController::Base def create @stats = Stat.receive_stats(STATS_SOURCE) sport_type = @stats["sportsID"] Stat.categories.each do |category| @stats["#{category}"].each do |stat| Player.store_stats(stat, sport_type, category) end...

0
Q: Why does the tableView twitch?

MikeI have a UITextView in a UITableVIew. I set the textView to be dynamic in height, and to scroll to the current position. The problem is, when the textViews text goes out of view, and it has to scroll to position, the whole tableView scrolls to the top and right after scrolls back to position. M...

1
Q: Get random direction based off of location and previous direction

ObicereI've recently implemented a Wilson's Algorithm for maze generation. This problem however could also be extended to things such as snake, or some other simple AIs. The problem is as follows: Blue Node -> Previous nodes Red Node -> Current node Black Line -> Wall In this case, we...

0
Q: Inserting nodes into a singly linked list based on size of number

jackdhGiven a set of numbers insert them so that the are ordered ie. add(5) add(3) add(6) add(2) Output: 6 5 3 2 GetNumber() returns the number of that term insertAfter() inserts that node after the pointer insertAtHead() inserts as the head node Term is the Node which holds the number How can I r...

 

« first day (682 days earlier)      last day (3342 days later) »