« first day (409 days earlier)      last day (3907 days later) » 

00:23
0
Q: Is there a difference between importing a package vs putting the full path when the method is called?

CeleritasIf you know you are only going to use a method once is there a point in importing it versus putting the full path to it? For example I know I'm only going to create one Random object from the class java.util.Random. Should I be doing import java.util.Random at the top or would it be better to do...

Yes. But off-topic.
00:40
0
Q: What would be a better way to write this?

Leinad177I was coding a plugin when i noticed that there was probably a better way of writing this. var $alldata = $("<table>", {id: "alldata"}) $('#resodetails').find('td').remove() $alldata.append('<tr><td>') $('#resodetails').appendTo($alldata) $alldata.append('</tr></td>') $('#portaldetails').append(...

0
Q: numpy: function to calculate the number of times a ray emanating from a point intersects with a polygon. How to optimize?

user89Here is the function (along with a support function): def produceDirectionVectorGivenDirection(direction): return np.array([np.cos(direction), np.sin(direction)]) def calculateNumberOfBoundaryIntersections(point, direction, vertices): neighbourVertices = np.roll(vertices, 1, axis = 0) ...

@nhgrif: I think that's enough flooding for today. :-)
Yea, lol. I took a break.
I think I'll just try to stay on top of current questions maybe.
Are there any questions left to retag?
A lot.
I guess there's less than 100 in that result.
But you can't just add to all of them. Some of them need and some of them are fine without either tag as the code is platform independent.
Some people have been improperly using for iOS questions... and there is no Cocoa on iOS. Only .
And either way, a Cocoa/Cocoa-Touch tag will only be appropriate if they're using classes from these frameworks. In iOS, it's the classes that start with UI. In OSX, the classes start with NS still, but it's only specific classes like NSView, NSTableView, etc.
Wow. After these questions get pushed off the front page, you can finish the rest in shorter bursts.
00:52
I already took care of any questions that were missing , which will be especially important as we start seeing questions.
I haven't looked at questions missing yet though. I'm only part way through the questions missing an OS tag. And I haven't touched the questions, but I'd be surprised if any of these were left after the others are handled.
Hey guys
hey @Phrancis
Anything to add here?
Probably will in a bit. Still working on this ugly SOB: codereview.stackexchange.com/questions/54388/…
This guy needs WAY more variables in his life...
Question from 2012 in the close queue? codereview.stackexchange.com/review/close/22335
with an accepted answer...
why not leave it alone?
@Jamal idea?
also:
I challenge those close votes. This looks exactly like the kind of person we want (and need) to help. — Loki Astari 1 hour ago
I skipped both
01:07
@Mat'sMug I closed another one, but not that one.
the one Loki is challenging had 4 close votes when I got to it.
Is he saying that the OP would make a good reviewer?
reviewee
Good @Phrancis. That questions needs more help than I can give.
@Mat'sMug to help. Ah, I missed that part.
...oh, that's C++, not C. O.o
01:11
@ckuhn203 yeah it's a bit of a headache really. Seems like SO MUCH CODE to do something seemingly simple. Reminds me of Russian dolls, a big one with a smaller one inside etc. etc.
new tag ... I don't like... am I wrong?
Yeah. I kind of threw my hands up.
I don't like either. I was just reviewing wiki edits and saw that one..
@rolfl I was hesitant as well. Would be better?
It'll get abused.
01:13
I tried putting in a tag usage guideline in the excerpt.
I like . That's much better.
technically is already good enough
Or both?
yeah both
retagged
01:15
dang
20
A: Creating .cpp, .c, .h. and .java file templates

Greg Hewgill Do not use using namespace std;, instead explicitly use std:: where required. Consider not using prototypes (which requires you to maintain the same function header in two places) unless necessary. This means putting main() at the bottom of your code and functions that it uses above it. Comments...

BURN
@ckuhn203 TBH I might rethink his code from the ground up, I think his approach (write a small select, write more selects around it, etc.) is not ideal
9 mins ago, by Mat's Mug
I challenge those close votes. This looks exactly like the kind of person we want (and need) to help. — Loki Astari 1 hour ago
@Mat'sMug I could've given a similar answer, but I wasn't feeling up to it. He needed the rep more than I did anyway.
yeah, yeah... ;)
@rolfl can you mod-hammer "leave open"?
01:20
Not entirely similar, but in bullet points (as usual). :-)
I'm not saying it doesn't need it. I just think there's more for OP to learn by creating some variables.
hmm it doesn't clear the close votes, I'm guessing another one and it's closed.
Loki has a C++ goldie, no? he could hammer-reopen it if he wanted...
Only for dupes.
oh
right
01:24
Sadly, that feature is useless on CR (except in those rare cases of dupes involving a migration and a cross-post).
02:15
(?<object>\w+(?:\.))*(?<identifier>\w+)*\s*\=\s*(?<expression>.*)
I feel like posting this for reviewing... :)
how do I not capture the dot ending each object capture?
@ckuhn203 got a clue?
hmm this "works": ((?<object>\w+)\.)*(?<identifier>\w+)*\s*\=\s*(?<expression>.*)
thanks @rubberduck!
0
Q: Interface and implementation of this replacement for Rebol/Red REJOIN

HostileFork This is a draft implementation of a function called COMBINE. Its purpose is laid out pretty thoroughly in this blog entry: http://blog.hostilefork.com/combine-alternative-rebol-red-rejoin/ But to make a long story short, it is supposed to let you flatten expressions into a string. It's not ...

Haha. I just saw this.
I need a rubber duck. My bamboo plant has stopped answering me.
3
I don't like the numbered capture group. Is there a better way to only match object when it ends with a dot, without capturing the dot?
It's more or less what I came up with before. I'm a regex noob though.
Specifically when it ends in a dot @Mat'sMug?
02:35
yeah
like in Form1.TextBox1.Text = "xyz", Text is the identifier being assigned to, but the identifier "belongs to" TextBox1 which "belongs to" Form1.
hmm I was going to call that class AssignmentOrComparison : Token, ...but then I just realized, a comparison would have an expression on both sides.... damn, how to tell an assignment from a comparison in VB?
I can't think of a way to do the regex without the group, but I've done assignments before.
1
A: Find and replace all names of variables in VBA module

ckuhn203You can use a regular expression to find variable assignments by looking for the equals sign. You'll need to add a reference to the Microsoft VBScript Regular Expressions 5.5 and Microsoft Visual Basic for Applications Extensibility 5.3 libraries as I've used early binding. Please be sure to bac...

0
Q: Implementing Todo in Haskell

Kevin MeredithPer Learn You a Haskell, I implemented a simple command-line program, Todo, that accepts 1 of 3 arguments: view or add or delete. Please review my code for Haskell idioms & overall quality. -- view, add and delete tasks -- borrows delete from previous LYAH exercise import System.Environment imp...

aw, you can't use named groups with that regex "flavor" :(
lol it's tagged with
Yeah. It was a lot of fun.
Long story short.
`.Pattern = "(\s)([^\.\s][\w]*)(?=\s\=)" ' list of variables
' begins with a space; next character is not a period (handles "with" assignments) or space; any alphanumeric character; repeat until... space`
It's not perfect. I couldn't get it quite right. It purposely excludes setting properties of objects. Not exactly sure what assignments you're looking for.
hmm...
foo = bar
foo=bar
foo =bar
foo= bar
foo.Bar.Text = IIf(x = y, "something", "something else")
If True Then foo = bar
If foo = bar Then
set abc = xyz
Project1.Form1.TextBox1.Text = StringFormat("{0}, {1}", "test", 123)
02:46
right click > view source — jeff 1 min ago
It should have found foo = bar, but not those other three. It relies on the IDE putting the white space in.
Hmmm
Lol
@Jamal I just voted to reopen, OP edited with code.
Okay
@ckuhn203 it won't match non-indented (or trimmed) code, that's why!
02:50
0
Q: how can i make my website have a more modern look

jeffhttp://jeffk.org i've been told by my bud "you know what this looks like? the nineties." i think it looks alright, maybe a little old fashioned but i've been staring at it so long now it doesn't seem that bad, i'd like some reviews from other people and some suggestions to 'modernize' it <!DOC...

Oh. D'oh. I was doing a global search on the whole file...
(^|\s)... Should do it.
So do we tell that guy that we review code, not graphic design?
nah, the code can be reviewed, OP was just closed and reopened...
Lol
Did that newline or space switch work?
missing foo= bar
and foo.bar.text = "something"
it fixed the need for indentation ;)
(^|\s)([^\s][\w]*)(?=\s\=)

That should fix the last case (I think, I'm on my phone)
I'm not sure how to look ahead with an OR. "(?=\s\=|\=)" maybe?
Like I said, I was relying on the IDE putting the white space in.
No. That's not right.
03:06
my tests are for capturing assignments and comparisons, not variables - I need to grab a property as a possible assignee, you're correct to not do that if you're capturing variables.
(^|\s)([^\s][\w\.]*)(?=\s\=)
Begin or space
Not a space
Character or period
Until space + equals
Could probably be simpler. Heading to bed though.
Night!
probably one @Kleinfreund would have a blast with: codereview.stackexchange.com/q/54468/23788
there are objective reasons why OP's site looks outdated/wrong.
03:36
Why.... why does his website want to use my location? Ummm, gonna have to go with no on that one.
Ah... There's a little weather widget. Still weird.
then again, i'm paranoid :p
04:11
Yeah, me too.
For websites that are built around some kind of location specific service (like a weather site, or Urbanspoon or something), it makes sense. Anything else sends up massive red flags immediately though :/. lol
I added a comment.,.... unrelated to the location thing
Good idea. He might not be expecting to get a review on the code and not what the code results in lol.
04:31
0
Q: Almost sorted interval (An array problem) code correction?

vaibhavI have been working on this problem on HACKERRANK in efficient way. I have other brute force solution of this which is working so fine. But this is something that is optimized(from my side). The problem is this code fails somewhere. I am unable to find out where. the problem statement : Y...

05:30
I need to go to bed...
goodnight all who also need to go to bed
and those who don't
0
Q: Head is initiating to Null each time when the insert_node() function is calling in the linked list

user46565Please Review the following code snippet. I am trying to insert elements into linked list using the double pointer concept. Problem is: Every time the 'Head' element is being assigned to 'NULL' which is not desirable except for the first insertion. please give the Suggesstions to resolve this ...

I'll be going soon.
lol
I am gone now.....see you tomorrow
@Malachi Good night.
@AlexL do you think that question is unfit for the UX site?
I don't even have an account there but I think it's the closest thing in the SE network to what he needs, isn't it?
if he fixed the horrible margins and alignment and that horrible font it would at least be on its way to looking passable
you know, maybe took the time to come up with a real logo instead of clipart
05:47
It's a poor website that does look fairly ancient!
I don't think it's suitable for any SE site
It's simply to large and subjective for one correct answer
it is really bad
well, there are widely-accepted design principles that he's breaking here
i figured they could at least address that
I completely agree
Here's UX's "Don't ask" ux.stackexchange.com/help/dont-ask
If he broke it down into smaller chunks then maybe he could ask there
Not just "How to make 90's website modern"
is that the boilerplate "don't ask"
05:50
With a little bit of originality at the bottom I believe
Actually no it's templated
I upvoted his question, and now that I've thought about it, I want my vote back!
that answer on there is the first one i've been tempted to flag as NAA
If we take a look at the "website-design" tag in UX ux.stackexchange.com/questions/tagged/website-design
You'll notice none are "make my site modern"
no, it looks mostly like people who know what they're doing and are asking decent questions
except for the closed ones
Exactly
It seems to me that he really needs to hire someone to get what he wants. There's not a SE site that's going to magically modernize his website for him.
05:56
if there were a reasonable place to answer this i'd take a crack at it
That, or do some more research. Making beautiful and modern websites doesn't just happen to someone based off a Q&A site
I have yet to vtc or flag either the question or answer
that comment was great though
Yeah... If he changed the focus of the question, it could be on topic, so I'm a little hesitant too.
@DaggNabbit :D which? One on the ques. or the one on the ans.?
on the answer :)
exactly what i was thinking
"just throw a bunch of libraries and crap at it, it'll look great!"
05:58
Yes! I hate when people assume that...
Especially when I talk to people in person, they may say, "make a website for that!" or "If only x was better on this site". Some just don't understand what it takes to make a modernized site!
morning @all
Hey there @chillworld
Our latest controversy has me all fired up
@AlexL from me?
@AlexL Seems to me its single biggest lack of focus. Right now, it's basically just a collection of random "stuff' with no noticeable relationship between one part and the next. Reworking the UI could help make relationships more apparent if there were any, but first you'd need content that had meaningful relationships.
@chillworld No no! We recieved an interesting question on website design
06:02
ah, link me :)
5
Q: How can I make my website have a more modern look?

jeffAfter looking at my site, I've been told by my bud: You know what this looks like? The nineties. I think it looks alright, maybe a little old fashioned but I've been staring at it so long now it doesn't seem that bad. I'd like some reviews from other people and some suggestions to 'modern...

Shivers
@JerryCoffin As soon as I opened his link and it aske dme for my location, I said, "Nope!!"
@JerryCoffin I think the content is just placeholder stuff, glorified lorem ipsum
Oh... my... goodnes...
Via his site: "Check out the revolutionary code that the JEFFK servers are running, nothing but next generation technology used by our developers."
@DaggNabbit Could be. If so, it's an even stronger indication that it's off-topic.
Hahahaahahahahahahaha
That's kind of amazing
06:05
And that links to jeffk.org/source
Also, just the idea of "next generation technology" is cringeworthy
I believe the giraffe really shows there "skill"
@Corbin It's a shame his question was asking for that type of technology
you mean severed giraffe head
oke, site is pretty clean,(seen worse) but have indeed an oldfashion look
06:06
We're still left with the need for worthwhile content, then design the site to show that content well. The "look" should be driven by the content though.
well, you really don't need content for design
I'd have to say that you do!
just look at the zillions of templates on templatemonster or themeforest
all design, no content
True, which is why I've never even downloaded the free sample ones
@DaggNabbit Already seen--and avoided, in part for that exact reason.
06:08
eh, those templates are money
client pays a few hundred bucks for a site, template cost $15, drop client's content in, done
@DaggNabbit You're develish....
lol hey i gotta eat
In mine opinion, the site is clean but looks indeed old fashion. The first thing I should do is considering what technology you want to go further. You can make web applications with asp.net or java, but this needs a lot of coding. You can go further with pyton, or if you don't want to have the code part minimal you can look at drupal or joomla. — chillworld 10 secs ago
if you really want to see a bad site
@DaggNabbit Enjoy.
@JerryCoffin i mean figuratively xD
gotta put food on the table
06:11
That's pretty morally grey.... lol
is it?
Then again, I suppose said clients never stipulated that it be a custom design :p
never thought of it that way
no, they don't give a shit
fordcapri.be (and click one of the 2 links
)
they just want it to look good
06:12
Yeah true. And a $300 cookie cutter site is much better to them than a $5000+ custom site.
bingo, everyone's happy
@DaggNabbit Yeah, I figured. I basically meant: there are better ways to do that than producing mediocre web sites, but if you and your clients are both happy with the results, have a blast.
@chillworld I'm loving the visitors counter at the bottom of the second link. It really compliments the colors of the repeating background image
depends on how you quantify better
i mean if i can make a few hundred bucks for an hour's worth of work and everyone's happy, why not
more free time to do interesting stuff
Most people aren't willing to pay what a well done custom website costs anyway. People have no idea how much they cost going in. It's quite annoying.
06:17
exactly... they want it fast, they want it cheap, they want it to look good
@DaggNabbit I like cars like that too...
@DaggNabbit I would quantify it based on pay and enjoyment. Life's too short to do boring crap just to support yourself (if you can avoid it).
but it's easy enough to hook it up to a django backend or something if they want to pay extra for a cms or whatever
@JerryCoffin i'd be willing to bet like 99% of people do boring crap to support themselves
@AlexL I know the owner of that site, he didn't believe that his site was shit
1 hour of shit work for the pay of 5 hours of enjoyable work will almost always win :/. (Which kind of says something about if I really enjoy any work... Lol)
06:20
we where with 4 in total in a course. The 2 other said the same :)
I'm currently doing crap work, but I'm about done
especially with forced 8am starts where I get snarky messages at 8:05
@chillworld Well I think the creator of said site needs to.... rethink his site a little ;)
Perhaps it's time to update this (perhaps including the question):
6
Q: Can I ask for a review on a website?

Tom GullenIs this OK or not really? If I develop a website template, CSS/HTML/JS, is it acceptable to post that as a code sample to be reviewed as an external URL?

@Corbin I s'pose. I quite enjoy (most of) my work, but I suppose there are probably other jobs that would pay better in exchange for the work being less interesting.
@AlexL rethink? I hope he hire someone cause I vote that in top 100 of ugliest sites on the internet
06:24
@chillworld 100!? Reduce that to maybe 10!!
@JerryCoffin Well, I'm also at the very begging of my career and haven't yet had a chance to figure what I like, much less angle myself towards that. I imagine at some point job-bearableness will become a much higher priority.
well, now I'm thinking of that, should I make meta post top 10 ugliest sites. (winner is the answer with most votes :D)
@chillworld I'd be interested in the results, not sure how it all related to code review though! :D
well, that's why in meta ;)
@chillworld I'd be willing to bet there are at least a couple hundred uglier sites around. Granted, most were designed in the '90s, but if you do some looking, it's pretty easy to find sites that haven't been updated in decades. Case in point: what used to be one of the best C++ compilers had a truly horrendous web site:
06:26
@JerryCoffin did you visited his site?
that site is even better
@JerryCoffin Oh my god. That's... omg. Even for the time period that's pretty grim.
That was a great link you provided Jerry... The sticky footer that flashes at the bottom is great
Hey chillworld, I think you have a couple site's for your new post
well, I gonna create the topic on meta now :)
I'll check to see if I have any stunningly baren bookmarked sites
@Corbin It is. I'm not sure if it has internal links to them, but there are (or at least used to be) a few pages on the site that were even worse. And no, it's probably not quite as bad as the previous link, but it's pretty awful, and only one I happen to remember, not the result of any real searching for the worst around.
06:32
0
A: Fun : Top 10 ugliest site on the internet

chillworldhttp://www.fordcapri.be/ You have to click on one of the servers to see the site what I mean.

let the fun begin :)
lol
you see not everything of belgium is good :)
Oh god...
wtf
the windows link
idk what's going on here
the url is not changing somehow
@DaggNabbit he implemented that you can take over his pc with the site, if you want you can search ;)
06:35
aha
it's a frameset
that's why the url doesn't change
fcapri.homelinux.com:8080 <- that's what i was trying to link to =p
@chillworld Keep the fun on chat please (within reason). Meta is not a free-for-all.
1
Q: Fun : Top 10 ugliest site on the internet

chillworldLet's have some fun here at meta. I know it has nothing to do with CR but see it as example's of how NOT to do it. Everybody may post 1 link to a site what they know and find themself the ugliest. Answer with the highest votes wins :)

I think if it was a little bit more code-review.se related it may have been good
@200_success Do I have to remove the question?
@chillworld Though they're mostly long gone, probably 9 out of 10 sites on Friendster and MySpace were at least as bad (and many were worse, or at least more obnoxiously bad).
06:42
Just search google for "Unix" "C" "linux" or a combination of server/system keywords, head to the 30+ page, and begin to see mayhem
On that note, I think I'll be off to bed, and hope by tomorrow the subject is back toward beauty instead of ugliness... :-)
Hahaha. 'Night
@AlexL i tried googling for "comic sans ms" and found this: chrome.google.com/webstore/detail/the-fantastic-comic-sans/…
night JC
@JerryCoffin Ha hopefully! Night
@DaggNabbit Downloads Uses forever Passes onto my grandchildren
06:45
A couple of the reviews ask how to get rid of it....
@DaggNabbit I find it creepy it has 401 users :s
I can just imagine it. "hahaha this is so funny. Haha... So... funny... How the hell do i remove this?!?!?!"
@chillworld 401 people installed it on their coworker's machine
Maybe there's 401 people out there who really love Comic Sans. I doubt it, but you never know. It's a big world.
0
Q: Improvements for basic and simple view, add, edit and delete functionality

UnknownI want to know what needs to improve with my application maybe there is a better way instead of what i am using currently. index.html code: <!DOCTYPE html> <html lang="en" ng-app="MyApp"> <head> <meta http-equiv="x-ua-compatible" content="IE=9" charset="UTF-8"/> <title>Angular JS</...

06:48
Guys I downloaded it
EVERYTHING IS COMIC SANS HELP
3
hahahahahaa
of the 6 reviews, 3 ask how to get rid of it and 1 explains how
Good thing I knew how ;)
Wow everything looks so much better?
@DaggNabbit I think you could be right :)
lol i'm not brave enough to try it
06:51
I really should get off this darn site... I made a promise to myself to go to the gym early tomorrow
@DaggNabbit I wish I had a site with my dog's stream of consciousness
nooo
i love the copy on his mockups
Well, goodnight all. Cya soon
speaking of websites that look stuck in the 90's
Monking!
07:13
monking @kleinfreund
@Yuushi stuck in the 90's but a beautiful clean html code :)
07:28
0
Q: How to implement emitters and listeners when the order in which events get called is important?

Alexis WilkeI have a server that loads plugins. The order of the plugins should not matter, although at this point it does, which is my problem presented here... The server first makes sure that all the plugins are loaded, then it start initializing them by calling an initialization function. There is an ex...

0
Q: Cleaning the ugly (mainly the repeated PHP section) of the code

AnaghThis is a script that I use to add a set of form fields on clicking an Add More button. <script> $(document).ready(function() { var InputsWrapper = $("#InputsWrapper"); var AddButton = $("#AddMoreFileBox"); var x = InputsWrapper.length; va...

first one off topic
pure theoretical with as good as no code in it
Well, that's ood. I have a never-ending load spinner on the 2nd Monitor, as well as on some wp sites. Some images won't load (chillworld's, ...). Can't upload new images to wordpress installation. Just shows broken image. O_O
wordpress.org doesn't load as well.
Somethings really fishy here.
@kleinfreund no problem at mine side
just did ctrl F5 on the browser, works normal
07:45
Nope, doesn't help.
2nd Monitor, CR, the WP site I'm working on... load spinner forever.
Same goes for Chrome Canary.
@kleinfreund what IP does wordpress.org resolve to for you?
or does it resolve at all
66.155.40.249
Monking @all
same here
that's weird
Not a browser issue. Firefox acts the same way.
07:49
oh, i bet it's an advertiser or analytics thing
some third-party thing that would be common to all those sites
that isn't resolving for some reason
It started happening after I migrated a wordpress site to a new server and deleted the Cache afterwars.
check network tab in console and see if something gets stuck
for example, your avatar doesn't load as well.
@kleinfreund: wordpress.org works for me
gravatar
07:51
Oh, gravatar
does wordpress use gravatar?
jep
Gravatar = Wordpress^^
then it's probably gravatar that's hanging
atleast here I get ERR_TIMED_OUT and ERR_CONNECTION_RESET
Don't get it in the WP backend, tho.
But I get a 403 (Forbidden) error for images I just uploaded to the site XD
07:53
probably wrong permissions =p
on your server
Yeah, might be unrelated to the other issue.
probably
Pah. Changing the /uploads folder to the correct permission set (0755 instead of 0710) and reuploading doesn't work as well.

« first day (409 days earlier)      last day (3907 days later) »