« first day (922 days earlier)      last day (3392 days later) » 

16:00
@Vogel612 I think the problem starts out with strings, so that is a given... But what is the faster way to convert into Long?
@EBrown Hmmm, I forgot to mention that detail.
(the summation numbers are 12-13 digits)
Because the compiler can build a jump table instead of having to recalculate the if each time.
@holroy there is none, but you're working on predefined numbers, so just use longs directly
(More scientific information for you to consider @Mast.)
16:01
@EBrown Fixed, thanks :)
@Vogel612 The predefined numbers in strings are 50 digits numbers...
And that is most likely to big for a Long in Java, or?
@EBrown Ah, yes, that works in multiple languages like that.
Then use BigInteger, these work on a CharSequence... that's faster than Strings
@Mast No problem. I think it's important for all developers to know exactly how things like switch and using work down in the gritty details.
Agreed.
16:02
Strings are slow in java, no way around that with the design choice of immutability
Otherwise it's a very good answer. :)
I should make a blog on this stuff.
Yes, you should.
@Vogel612 I can agree that immutability can affect string operations requiring some sort of changes, but when they are just doing a substring and converting into a number, there really isn't any excuse for not making that blistering fast
First I would need to setup a blogging platform. :/
@EBrown Nah... You can use Facebook Notes! :-p
16:05
@holroy Shoo!
@holroy I see we have a comedian over here. ;)
HeHe...
@EBrown When in doubt, just get yourself a wordpress.
lol, idk what that is
@Mast I don't have any servers that are PHP.
I only have ASP.NET servers.
16:05
Facebook is not something I intend to use. Ever.
@EBrown You don't need one. They go for free.
@Mast I'm just going to use blogengine.net.
@EBrown You got a domain yet?
@Mast I have about 2 dozen domains.
I'm going to make it a subdomain of my main domain.
What about Jekyll?
16:10
Jekyll?
0
Q: Wrapping tuples to be used as keys in a Dictionary

VincentI'm currently working on a project where I have to map some objects to several properties. Basically I need a Dictionary with Tuples as keys and instances of MyClass as values. As using tuples can quickly lead to an obscure (because of item1, item2... properties) and verbose code I decided to m...

I always mix up the brackets.
Sorry @Boni, as I said a few minutes ago, I only have ASP.NET servers.
It's just serving static pages.
But it's a Ruby Gem, no?
16:14
Yep. Which can be done locally.
I have a quick C# question
possible answer invalidation by guillaumevincent on question by guillaumevincent: codereview.stackexchange.com/posts/110559/revisions
Well, whatever works already.
I'm not comfortable installing Ruby on this server.
@EthanBierlein Which is?
Is it possible for classes to inherit from classes that use generics, like FooBar : Bar<Foo, Bar>?
16:15
yes
Entirely.
0
Q: Cross validation of gradient boosting machines

RUser4512I am fairly new to python. I implemented a short cross-validation tool for gradient boosting methods. import numpy as np from sklearn.metrics import roc_auc_score as auc from sklearn import cross_validation from time import time def heldout_auc(model, X_test, y_test): score = np.zeros((mod...

@EthanBierlein the only drawback is if your'e doing COM interop.
16:22
Hello
huzzah!
> With Cloud9 we're lucky to be working on a product incapable of sawing off appendices. But we still can do some really awesome things with it.
0
Q: Error with HTA reading pwdLastSet AD attribute

STGdbWe have an AD domain that is at 2008 R2 levels. I have written a HTA which I use by right-clicking on a user from within AD Users & Computers and then selecting the HTA from the context menu that appears. The HTA gives me the display name and UPN for the user selected and allows me to hide the ...

@CaptainObvious Broken.
Unclear what you're asking, but looks like you are looking for codereview.stackexchange.com. — Christian Hackl 6 secs ago
@ChristianHackl I did not know about codereview. Thanks! — Anuj Saharan 56 secs ago
@ChristianHackl, Whilst Code Review does handle reviews, and some optimisation of algorithm, the code needs to be in working conditions firstly! Please see a Guide to Code Review for Stack Overflow usersholroy 1 min ago
Reviewing and/or improving existing working code is normall better suited to Code Review. — Equalsk 7 secs ago
16:39
lol
@holroy: I know. I did not mean that this question could be transferred to Code Review as it is, but clearly the author's intention is getting a review of the code. — Christian Hackl 57 secs ago
@Equalsk the nature of the question appears to indicate that the OP is looking to rewrite this routine with a different technology than VB. As such, this would be off-topic on Code Review as "code not written yet" (in the target technology). — Phrancis 59 secs ago
Yay! Got to 1K. Thank you Santa!! :-D
4
Welp. Almost rep capped on SO from a single answer. I guess this was a productive day.
@SuperBiasedMan I got 100 on that answer and 10 from two other questions.
16:48
0
Q: finding the longest palindrome - javascript

devdropper87I wrote the following function to find the longest palindrome in a string. It works fine but randomly it won't work for words like "noon" or "redder". I fiddled around and changed the first line in the for loop from: var oddPal = centeredPalindrome(i, i); to var oddPal = centeredPalindrome(...

0
Q: Algorithm to add all lucky numbers under [N] to a Vector

Anuj SaharanA lucky number is defined as a positive integer whose decimal representation contains only the lucky digits 4 and 7. For example, numbers 47, 744, 4 are lucky and 5, 17, 467 are not. Now, suppose I want to add all Lucky Numbers under a given integer [N] to a vector, without using recursion. For ...

@ambigram_maker Nice answer :P
I write answers to questions that inspire me. Project Euler always inspires me... Forces me to think differently.
That's a more noble reason than my "because code being bad annoys me"
Dear friend, welcome to SO. Just to inform you, this question belongs to codereview.stackexchange.comRajesh 39 secs ago
@holroy My Lenovo laptop is ancient. Intel has declared end of life for my processor. You can see the specs in my latest question (the Parallel Multiplier one) ;-)
16:54
@DanPantry Isn't it marvelous?
Wait... how do you star a message on a smartphone?
@ambigram_maker You don't...
@Phrancis lol
I didn't even know you could use the chat on a phone. Is it not horribly unoptimised?
@ambigram_maker We got Theoretical Stars for that
16:55
Yup...
Can't load my last message.
@ambigram_maker That was kind of out of context... Had expected a response in comments, not here in chat... We had a little ramble earlier on by the way related to this question and why the Java version were so slow compared to the Python versions...
@Mat'sMug I invited you to chat. Would invite @Vogel612 but he isnt online atm.
BRB picking up my glasses
But it (using a smartphone) helps with typos. ;-)
@SuperBiasedMan it works but features are stripped down a lot...
0
Q: On Javascript code Where, when, how, check function arguments??. Best practices

Piter KaterI have this functions definitions: // This is a private function, don´t check for undefined arguments. function _arrayKeyDiff(a1, a2) { let r = {s:[], n: [], l: []}; for(let k of a1) if (a2.indexOf(k) === -1) r.l.push(k); else r.s.push(k); for(let k of a2) if (a1.indexOf(k) === -1) r.n.pus...

16:57
Kinda weird to be the odd one out.
@Phrancis You can always chat using a mobile phone, using the full site.
Uff. Not nice.
^that
@Rajesh The wording is somewhat unclear (I get the impression the OP might not be a native english speaker) but if they're just asking about "How should I handle unexpected inputs?" then it would be Off-Topic for Code Review. We review code that already does what it is intended to do, not feature requests. If the OP wants general feedback on what they've already written, that would be a perfectly fine question. — Zak 40 secs ago
16:59
@ambigram_maker See this and following...
Opinion-based questions are off-topic here, but if you have working code that you'd like feedback on see Code Review (they will want actual code, not stubs as you've shown here). — jonrsharpe 18 secs ago
@Zak Thanks. I was under impression, all reviews and improvement question belongs to Code Review and we just post issue here. I'll be more careful in commenting from now. — Rajesh 17 secs ago
Well, blog is setup and first post is in.
What is the post on?
17:02
bookmarked
Just the basic "about" post.
Is that intentional or just a placeholder for now?
I have someone working on a theme for it now.
The entire theme is placeholder.
@rajesh that's quite alright. The golden rule of recommending Code Review is: "Does the code already do what the OP wants it to do?" and they just want advice on how it could have been done better. You might also want to read A guide to Code Review for Stack Overflow UsersZak 37 secs ago
@holroy I guess you got your answer. Also, may I add that the JVM takes some time to warm up.
Lol @SuperBiasedMan I got your chat comment now, on the app.
17:05
@ambigram_maker It has to start the coffee pot and wait for it to brew :)
8
0
Q: Is this a JavaScript constructor pattern?

Jamie LittleI've been using this pattern in my JS code: function Thing() { var otherData = { // Private variables? name : "something" } var myThing = { data: "somedata", someFunction: function () { console.log(otherData.name); } } return ...

@Phrancis HeHe... So sad, and so true...
Somebody star @Phrancis 'S post for me please. ;-P
@EBrown Are you going to tweet out posts? If so, let me know your hande, or add @Cardshifter and I'll RT when you post!
17:07
@Phrancis Yeah, and it's @EBrown8534 on Twitter.
Whoa... I got to know now... You can star a post on chat if it has been starred at least once. Uff!
@Rajesh OP decided to follow your advice and posted it on Code Review. At the moment it has -2 and 3 close votes. Please refrain from making such recommendations if you're not sure how the next site will take it. — Mast 29 secs ago
2
possible answer invalidation by budi on question by budi: codereview.stackexchange.com/posts/110495/revisions
Now I need to install GCC on my Debian setup.
Wat? I thought it came inbuilt. It does for my Ubuntu.
17:11
@EBrown It isn't installed by default?
@EBrown Are you going to be focusing on any set of technologies in particular, or more of a general programming column?
@Mast No idea.
@Phrancis I'm going to be focusing on all technologies that I run into. The majority will be .NET, SQL, JavaScript, C, or C++.
@EBrown Sounds good, feel free to drop a link when you've written your first.
Most definitely.
Now I need to get Git installed on this laptop.
17:16
It's Debian, can't be harder than a one-liner on the terminal
Well what I really mean is I need to learn how to use Git on Debian. :P
git clone https://xyz
To commit:
git commit -m "Message and all"
To update:
git pull origin <tree>
To push commit:
git push
I would assume git works the same on any setup if using the terminal/command line...
Have anybody here used AutoReviewComments for templating comments? I'm wondering on how to add a new comment message on Stack Overflow
12
A: Frequently Posted Comments

Simon ForsbergThis is intended as a ready copy & paste version for including in the Auto-Comments script. The Auto Comments script also has support for a "remote" feature where you can use this URL: http://www.zomis.net/codereview/auto-comments ###[Q] Broken Code I'm afraid this question does not match what ...

TTG, meeting
17:21
@Phrancis I've never used the CLI for Git.
I've migrated this post to our sister site, Code Review, since it is working code but you want to receive feedback on how to make it work better (faster, but you can do with some style tips too). — Martijn Pieters ♦ 49 secs ago
@Mast That gives some predefined texts, but I want to write some of my own. Is it easiest to import these, and then change them?
When you click the import/export link on the pop up window you can just write them directly in.
@EBrown Git reference guide (has pretty much every command you need)
0
Q: RockPaperScissorsV2 follow-up Advanced

DeliriousSyntaxI have posted my first version of RockPaperScissors a while back. It was on an old version of python with improper use of some functions. This version was updated to a more recent version of python and has a little extra for users who run on terminal. Is there anything I should add or change? Are...

1
Q: New to python and code optimization

MrUglamaI'm relative new to python scripting, and I made a script the takes two raw data files, and merges them into one cvs file, but it takes a long time to complete, is there any logical structure I'm not aware of? input_fileVms = open( 'vms.csv', 'rb') if site == 'eg': output_merge = open('merg...

17:26
@Phrancis Ah, nice!
Hmmm. Sometimes programmers get a little carried away with names - "doRunRunRunDaDoRunRun"
5
@SuperBiasedMan Do you know what the Q, A, C, EQ stands for in the ###x
public String oldMacdonaldHadAFarmDooDa(string DooDa)
Q = Question, A = Answer, C = Close Vote and EQ = uhhhhhhhhhh. Not sure, suggested edit reject reason maybe?
<afk>
17:31
I mostly use Q and A
@SuperBiasedMan Makes sense... But I thought C was comment, so it didn't work changing them for a while... :-(
Ah, no it's what they're in response to. Q is for a comment you'd post on a question etc.
Found some information on github:
Closure : "C",
CommentQuestion : "Q",
CommentAnswer : "A",
EditSummaryAnswer : "EA",
EditSummaryQuestion : "EQ"
I guess the last two are related to tags? I haven't seen summaries other places, at least
Say... Will anyone listen (or even better, back me up) if I request for an improvement to the Chat interface on meta.SE?
@holroy at one point I had the "Q" ones as "C", but they're better off as "Q" because "C" would be a custom close reason - and "broken code" isn't a custom close reason
17:34
For smartphones.
@ambigram_maker it's tied to site design
i.e. when CR gets its design, The 2nd Monitor gets a new design too
@holroy no it's about the edit summary when you edit a question or answer (or actually post in general)
Hmmm. So what do I do?
ask a redesign of the beta-blue chat CSS?
@Vogel612 Yeah... Good to know!
17:36
designers are busy enough as it is though - and I'd rather know they're working on our site design than on improving the beta-blue chat ;-)
Okay... I guess I'll have to make do.
@ambigram_maker for smarphones there's ChatSEy
that's an external collection of stylesheets and small helpers for mobile chatting
as I understood, mobile isn't really supported for chat
@Vogel612 links please (if any)
there's an android app.. should be easy to find in the playstore
if you want the chat to look different in your browser, there's an extension for chrome and firefox, the SO Chat Dark Theme by rlemon
I couldn't live without ChatSEy
17:39
@Mat'sMug I found it unhelpful, actually. YMMV
switching between rooms, knowing who's in the room, starring stuff - all very hard without ChatSEy
of course it lacks the mod & room-owner tools though
I don't usually switch rooms on mobile. I'd just keep a tab with all the relevant rooms
and use the desktop version
0
Q: Want to show Tick sign when user fills a textbox

Areeshai am developing a website in asp.net using c#(html 5.0). i want to show tick sign when user fills a text box correctly.want complete method or code for it.plz help me.

You might want to use Code Review. — johnny 43 secs ago
@CaptainObvious shoot it..
17:44
OK.. First post using ChatSEy.
@EBrown You should type "Using Programming" instead of "using Programming". It's very confusing :p
@TopinFrassi The name is "using Programming;"... Even more confusing... :-)
u sing programming
5
@TopinFrassi The C# syntax is using Programming;, it's meant to be a play on that.
Isn't Duga a bot? Where the 127 rep come from?
17:51
@ambigram_maker Bot's have to follow the same rules as users, so before @Duga could get in chat it needed reputation.
@Duga needed rep to be able to post.. .^^ that
@EBrown Yeah I get the point, but, for example, this : "What is using Programming;?" Is confusing. Is it about a tool that's used by Programming? Is Programming a tool? It's confusing IMO.
Did the creator of @Duga (who?) make a few posts to give it the rep?
Anyway it's just a feedback I'm giving, feel free to use it or not :)
@ambigram_maker Yes, @SimonForsberg did.
17:53
@EBrown @SimonForsberg Hmmm... Enlightening.
@ambigram_maker actually it was probably mostly edits
You can check in Duga's activity section on the main site profile
11
A: Inserting data in 3 tables of a database with JPA

Duga What my main question is, is since I'm new to JPA if I'm using an efficient way to insert the data fetched from the Twitter API in my database. Well, it's not entirely bad, I understand that you need it because only your sqlmanagement.XXX classes are annotated with @Entity. You could improve...

^^ only Duga activity on CR
@Vogel612 +120 from that answer's upvotes, +15 from the checkmark, total +135, +1 = 136. there were no edits ;-)
@Duga There you go... +10 for you.
@TopinFrassi You only meant in the "About" post?
@Mat'sMug yeap.. guesswork proved to be wrong
17:58
If so, I've updated it.
JavaBot had edits...
http://codereview.stackexchange.com/a/110589/72910
^ Pleeeeeease delete me, let me go
though SO needed edits more than answers and you get the 100 rep quicker by doing 50 edits instead of posting answers on SO
> Please, see our help center before asking. No Stack Exchange site spoonfeeds code. – Mat's Mug♦ 14 mins ago
^^ that was on her question a few minutes ago
some users seem to want a ban
Or think it's just some meanies who don't want to give the codez
18:00
Looks good to me, assuming it works. You might get better answers on Code Review. — Kevin 52 secs ago
yeah SO/SE is so hard on noobs
@Mat'sMug no not really..
it's hard on people who can't or won't show effort themselves
s/noobs/people that can't be bothered to ... ^^ that
It can also be hard on noobs but SO ain't the problem here.
So the first post about code on my blog includes C code.
18:03
Gotta run home and eat. Later folks.
@EBrown Well, it's where it struck me the most!
Oct 22 at 0:27, by Ethan Bierlein
type Frefarasdf = class end
okay I'm losing hope. anyone has any idea how to get a SSIS package to run through a SQL Agent job that's not owned by a sysadmin, using a proxy? I get the job to run, but the package fails with an authentication error - which makes no sense because the job itself authenticates correctly
about to hit DBA.SE with that one
@Mat'sMug Go for it... (I can only say that and do nothing else)
@Kevin It's just not asking for a code review at all. — 200_success 29 secs ago
@200_success: "Is this the canonical way of doing this, or am I missing something?" sounds like a code review request to me. — Kevin 12 secs ago
18:11
Okay. Time to do my Homework from 12 am to 2 am... Possibly 3 am. Ciao.
I'm voting to close this question as off-topic because it belongs on Code Review, not Stack Overflow. — ArtOfWarfare 32 secs ago
In addition to this being off-topic, I think you should edit this question to include the implementation of newthread. They're definitely going to want it if/when this gets moved to Code Review. — ArtOfWarfare 30 secs ago
@ArtOfWarfare This would likely be closed on Code Review as stub code, due to the omitted code here. If the OP provides the full code, and isn't asking for new features, then it's on-topic. — Ethan Bierlein 5 secs ago
@ArtOfWarfare 1. Speaking as a moderator of Code Review, I guarantee you that this question would be immediately closed on Code Review, for the reasons stated above. 2. "Because it belongs on Code Review" is not a valid reason to classify this question as off-topic for Stack Overflow. See the help center for a list of valid off-topic reasons. Also read A guide to Code Review for Stack Overflow users. — 200_success 24 secs ago
0
Q: For loop counter declaration

CeceXXI wonder which for loop looks clearer, is more readable and performs better: for (int i = 0; i < arrayLength; i++) { ... } Or... int i; for (i = 0; i < arrayLength; i++) { ... } Notice the counter i declarations. Does it actually make a difference performance-wise if I declare the i...

http://www.commitstrip.com/en/2015/11/12/pay-to-pitch-to-randoms-the-next-big-idea/
CommitStrip
Pay to pitch to randoms, the next big idea!
CommitStrip
1447352405
6
@Mast I hope I can :D
Just had this diagnostic test of applid natural sciences, I was late because of a traffic jam, and then they start asking things I don't even know about, great :| Was totally useless
It wasn't even stated what the test was about
University logic never disappoints
Windows 10 is finally starting to make sense...
18:32
@skiwi Finally ahah. The csv thing was terrible
As a gamer, I want a version of windows with DX12. As a sane person, I want a version of windows without the built-in spyware. So, I'm stuck at an impasse unless/until I can motivate myself to add the necessary firewall rules to my router :|
0
Q: Email Checker - checks if you have included the @ sign, provider and domain extension

SamCodeTo learn about classes, I chose to create a little something that checks if you have included the following: @ sign Provider (e.g. 'hotmail') Domain extension (e.g. '.com') It also checks if you entered spaces in the address and gave the option to keep them or get rid of them. It's all writte...

@CaptainObvious One of these again?
@DanLyons Motivate yourself!
@Phrancis There's not even a standard standard for email checking
I've been putting it off until I build a new machine :P
18:35
There's only non-standard standards
@skiwi Yeah, email checking seems like a mostly fruitless activity...
I'm voting to close this question as off-topic because this questin belongs on codereview.stackexchange.com — Mike Brant 1 min ago
@DanLyons I'm planning to upgrade my desktop PC to W10 with a clean install once I buy a 1 TB SSD, which I will only do if I decide to put my current 250 GB SSD in my laptop and stick 16 GB RAM in it, and then I'll also install the laptop OS
Probably would make more sense to do something if and when the mail server returns an error after sending an email
Thing is... 1 TB SSDs are still fairly expensive and I'm still not sure if I want to upgrade my laptop or buy a new one
Result: W10 is not installed yet on my desktop
Don't hold off on things ^^
18:37
I figured I'd get a ~500GB SSD, but I want an NVMe, U.2 variant
I can't really convince myself that I should upgrade from 250 GB to 500 GB
0
Q: How can PHP code be made aware of specific class subtypes passed to it, when using polymorphism?

DennisNote: similar to http://stackoverflow.com/questions/33677793/how-can-php-code-be-made-aware-of-specific-class-subtypes-passed-to-it-when-usi I have a class called Assembly that hides implementation of underlying products. ProductA can have one set of getters, ProductB can have another. Whil...

19:28
there you go:
0
Q: Running SSIS package from SQL Agent job owned by a non-sysadmin domain user

Mat's MugI have two SSIS packages that run scheduled overnight (via SQL Server Agent) as part of a larger SSIS deployment, without any issues. Everything is using Windows authentication, and the scheduled job is owned by a sysadmin (well, me) and run as the SQL Server Agent Service Account. So, the data ...

@Mat'sMug ugh, sounds like a PITA
indeed
there might be a [much] simpler way that I don't know of though
I'll probably end up giving my association bonus away as a bounty on that one
19:49
0
Q: Set Hyperlink to a label in excel cell using Apache POI

prasatarunI am working on a small tool using Java to update the Hyperlinks in an excel workbook automatically. I am using Apache POI API . Some of the cell has text and a URL with label. how would i replace the hyperlinks alone, without impacting the text in the cell. code snippet: Hyperlink link = create...

This might get better responses on Code Review SE. You've got a good start, as phflack mentions you want get/sets on some of your Node and Edge properties. I'm not sure why you want to avoid Graph being a Collection (List or Set or ...) of Node and Edge, it seems a perfectly logical way to represent a weighted digraph. — cobaltduck 5 secs ago
there is a whole stackexchange site dedicated to code reviews — redFIVE 13 secs ago
The question is kind of general, and may be better suited to codereview.stackexchange.comB. Clay Shannon 48 secs ago
@redFive is correct, this would be a better fit on Code Review - note that you don't need to "simplify" the code you post there, in fact it's actually better to include all of it; reviewers like to see your code in its full context and glory! :-) — Mat's Mug just now
So apt-get install git doesn't work. Awesome.

« first day (922 days earlier)      last day (3392 days later) »