Open Side Menu Go to the Top

09-14-2014 , 03:59 PM
There's no such thing as non accessible html. There's accessible html and wrong html. Writing html in a way that at least passes achecker.ca should be the responsibility of anyone writing html, if not, it doesn't pass code review.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD **
$25m Guaranteed WPM on CoinPoker
Join the action now
Daily Rewards • Splash Pots • CoinRaces
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD **
09-14-2014 , 10:28 PM
Way back when, I was obsessed with "good" HTML and accessible HTML in particular. After a lot of CTR-U, I found much disappointment. Most sites don't have the time, resources, or knowledge to implement this stuff.

HTML, CSS, and the languages used to build websites are broken technologies. One only need to look at all the frameworks and broken security. At some point, something is going to break, and someone is going to create an entire new paradigm. I suppose at that point, accessibility will be one of the many front-and-center goals. The big issue is that the web, at least today, is predominantly a visual medium. This is a business as well as a cultural issue. The current ideas do poorly for all levels of accessibly below perfect vision, health, hearing, income, etc.

While the ideas of accessibility are important, at least in the sense of "don't be a jerk," the implementations are a balance of commerce and time. Each new feature is a new database call and code that needs to be written. Then how do you ensure that your marketing intern fills in all the fields right when she is entering new page data? How do we keep ideas and data consistent today, tomorrow, next year, and next decade?

If I'm selling eye contacts, how much do I really care if a blind person can navigate my site? This is an extreme example, but no different than choosing to support IE8. I don't think it is a good idea to enforce accessibility laws unless your building websites for the government.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-14-2014 , 10:29 PM
Quote:
Originally Posted by Grue
There's no such thing as non accessible html. There's accessible html and wrong html. Writing html in a way that at least passes achecker.ca should be the responsibility of anyone writing html, if not, it doesn't pass code review.
No.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-15-2014 , 08:13 AM
I have an algorithm question for you guys, in Python 2.7.x.

Let's say you have a file with a list of sorted hex color codes (ie, #000000 to #ffffff) and you want to create an algorithm that lets you do this:

pick_awesome(42)

And it would return 42 colors in a list that are not too bright but not too dark, and are also not too close to each other. Basically 42 pleasing colors that work well together on a white background.

The use case is they would be edges for a graph that draws lines with 42 nodes. Lots of lines/arrows/etc.

My current algorithm is very boring, it just chops off the brighest/darkest 150 colors and uses the random module to pick them but the outcome is usually terrible and very lop sided. I really want to improve it.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-15-2014 , 08:37 AM
I don't know enough about actual colours/colour theory - but could you skip the list of hex colours and just generate the values you want yourself?

So like pick the darkest red, blue, and green based colours you like, the lightest red, blue, green based colours you like, and then decide how many colours in between to pick based on the number you want?

I guess this would skip a lot of possible colours, but might end up with a better end result than randomly grabbing values?
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-15-2014 , 08:49 AM
Hmm jj, the input number is unknown. It would be anywhere from 3 to probably 300ish.

I guess I could hand select 300ish nice colors but that's a lot of work. Although it may be the easiest way to make a consistently better outcome.

The problem I have is it often puts a few really bad colors next to each other too. Like 2 bright greens or a ton of the "almost the same" colors near each other.

I thought about doing some hacks like pick 1 random color then as I loop through my data I'd add something like 30-60 to that random color's index and pick that color. Then use modulo to make sure it wraps around the highest index, but it seems kind of hacky. It might help to stop colors being too close to each other tho.

Last edited by Shoe Lace; 09-15-2014 at 09:03 AM.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-15-2014 , 09:06 AM
I was thinking you calculate the offsets from your colours based on how many you need.

So you divide the distance between your darkest and lightest colour by the number you need to pick.

Like if 00 was your lightest and ff was your darkest (or other way around, I always get it mixed up) and you need 3 colours you'd pick 00,7f,ff. Or if you needed 16 colours you'd pick 00,11,...,ff. Rotated amongst the 3 colour bases.

Edit: ****, hex math is hard so I give up.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-15-2014 , 12:41 PM
Quote:
Originally Posted by Anais
Question for any web designers here: how much focus do you put on accessibility when designing a web page or web app? The HTML class I'm taking atm really puts a huge emphasis on it, and I understand why, but I'm curious how much actual employed folks in the industry do it.

By accessibility I mean alternate text, descriptive attributes in table tags, etc. Stuff for people with disabilities mainly.
We build 100% of our sites to follow ADA Section 508 Compliance.

Clients sometimes ask about it proactively (rarely), but we usually mention it at least in passing to every client. They usually just respond "that's good" or "we require that", etc.

I have never had an objection related to it or a suggestion to not follow it if it adds cost. Which in thinking about it I am a bit surprised, as some people will look for every angle to cut cost, the fact this has never come up as one it seems like people just blindly accept it is a reasonable expectation for a website.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-15-2014 , 03:46 PM
Guise, Quick question for a buddy of mine.

Which language do you think is best for a complete beginner ? Java, C++, Python, VB?

Cheers
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-15-2014 , 04:17 PM
Python > Java > C++ >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>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>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>VB

Last edited by jjshabado; 09-15-2014 at 04:17 PM. Reason: Forgot a >
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-15-2014 , 04:30 PM
Quote:
Originally Posted by TopPair2Pair
Guise, Quick question for a buddy of mine.

Which language do you think is best for a complete beginner ? Java, C++, Python, VB?

Cheers
I learned BASIC as a complete beginner in around 1988 at 11yo and python as a revirginized beginner around 2011 and I prefer python. So not BASIC.

I've since learned javascript and C as a seasoned veteran and think they wouldn't be the worst choices in the world either, depending on what kind of programming you want to do.

Consensus on the web is that among those four candidates it's python by a mile.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-15-2014 , 04:40 PM
sweet! Cheers guys... I was thinking Python myself but as I am not a seasoned pro myself or anything was just wondering if it made more sense from a general standpoint to learn something other than python first.

Appreciate the quick comments.

Peace and blessings moffos

Last edited by TopPair2Pair; 09-15-2014 at 04:40 PM. Reason: >>>>>>>>>>>>>>>>>>>>>>>>>>>> = lol
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-15-2014 , 07:24 PM
Quote:
Originally Posted by Shoe Lace
Hmm jj, the input number is unknown. It would be anywhere from 3 to probably 300ish.

I guess I could hand select 300ish nice colors but that's a lot of work. Although it may be the easiest way to make a consistently better outcome.

The problem I have is it often puts a few really bad colors next to each other too. Like 2 bright greens or a ton of the "almost the same" colors near each other.

I thought about doing some hacks like pick 1 random color then as I loop through my data I'd add something like 30-60 to that random color's index and pick that color. Then use modulo to make sure it wraps around the highest index, but it seems kind of hacky. It might help to stop colors being too close to each other tho.
I'd try something like this. Disclaimer: Not a color theory buff, either, so be warned.

Start with FFFFFF. (or more likely skip this one for displaying purposes)
Use mod 6 to pick which color components to modify. Red, green, blue, red & green, red & blue, or green & blue. If you want greyscales, make it mod 7.

So now I'd assume that the mod operation places them into potentially similar colors (only saturation will change).

From there it's some weird binary picking where you basically always add the half way points between the points from the previous run, starting with 00 and FF.

Maybe an approach is to use the div 6 number plus/minus some offsets and use that to do an imaginary binary pick from a sorted array of 255 numbers.
Initially, you'd first pick FF then 7F.
From there, in the next round, you can make two picks, so binary representation 0 or 1 to determine the upper or lower half to pick.
The next level will have 4 potential picks, the level after that 8, etc.

Maybe something like this could work:
If x div 6 = 0, return FF.
If x div 6 = 1, return 7F.
Otherwise, start with 3 points. 00 (min), 7F (pivot), and FF (max).
Take x div 6 minus 1 and represent in smallest binary representation possible (i.e. strip leading zeroes in binary).

Going from the least significant bit towards most significant, do...
0 means calculate the middle between min and pivot. Replace max with pivot, and pivot with the number calculated.
1 means calculate the middle between pivot and max. Replace min with pivot, and pivot with the number calculated.

When you're out of bits to process, return pivot.

Put the returned value subtracted from FF into the color components picked by the mod operation (the not-picked ones are FF). That's your color.


I just made that up on the spot, so probably some massive holes in there. Anyway, that's what my first attempt would look like.

Edit: Actually, stripping leading zeroes is incorrect (you'd always end up picking one specific half in the last operation). You rather need a log2 calculation to determine how many bits to process.

Edit2: Had to reverse the starting point and change the use of output. Forgot that FFFFFF is white, not black.

Last edited by kazana; 09-15-2014 at 07:44 PM.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-15-2014 , 08:14 PM
After some more reading about the color shenanigans, I saw how inappropriate a linear approach is. (Might still just work.)

Another option may be to calculate colors randomly, then compare for a sufficient distance between key points. Keep those on file with ever decreasing distance as you add more.

See this link for an algo they use to calculate the distance.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-16-2014 , 07:56 AM
Quote:
Originally Posted by Shoe Lace
I have an algorithm question for you guys, in Python 2.7.x.

Let's say you have a file with a list of sorted hex color codes (ie, #000000 to #ffffff) and you want to create an algorithm that lets you do this:

pick_awesome(42)

And it would return 42 colors in a list that are not too bright but not too dark, and are also not too close to each other. Basically 42 pleasing colors that work well together on a white background.

The use case is they would be edges for a graph that draws lines with 42 nodes. Lots of lines/arrows/etc.

My current algorithm is very boring, it just chops off the brighest/darkest 150 colors and uses the random module to pick them but the outcome is usually terrible and very lop sided. I really want to improve it.
I saw some solution to this on HN but can't find the one I'm looking for, here's some links though of some that look OK:

http://martin.ankerl.com/2009/12/09/...grammatically/
http://llllll.li/randomColor/
http://www.checkman.io/please/

Algorithms to pick colours in that way are actually pretty difficult to write yourself last time I looked. There's a lot of theory behind it and the relationships between hex colours don't always work as you might think they would.

Also storing a sorted list of all hex colors doesn't make too much sense (can be OK sometimes though I think) as it's similar to listing/storing sequential numbers. Not too important though but just something to think about maybe (and I know you might of just phrased it that way to frame the problem more clearly).
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-16-2014 , 09:34 AM
Thanks, I'll check them out.

Gull,

Yeah, it's not quite 000000-FFFFFF. It's only colors supported by the X11 standard, but in hex format. The sorting was so I could chop off the darkest and brightest colors by just slicing the list.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-16-2014 , 11:42 AM
Quote:
Originally Posted by jjshabado
https://moderncrypto.org/mail-archiv...14/000780.html

Really interesting post about GMails spam filtering and how it would relate to end-to-end encryption of email.
On a related note:
https://www.indiegogo.com/projects/p...y-privacy#home

Dunno if there are any other projects but I'm pretty happy that there are some people that finally got that crypto is not the problem. Making it easy as **** is. Hope this gets funded, I'll fund it.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-16-2014 , 11:53 AM
Quote:
Originally Posted by Anais
Turned in a project today for c++ that was basically a comparison of golf scores followed by announcing the best, or lowest, score. My program worked, but I feel like I didn't have the most elegant solution for figuring out who was best.

I did the whole program basically discarding anyone with higher scores, so only the lowest score was kept track of. To start, I initialized a variable for the low score to 0, then did an if, else to have player 1 always put as the best score, followed by any subsequent player' scores compared against player 1.

I would have preferred to do this all in one bit of code, and I could easily do it if we were comparing high scores. (high = 0, if score > high, high = score) But I couldn't for the life of me figure out a way to do it for scores where lowest is best. (Other than maybe initialize the best score to some absurdly high number, but again, that doesn't seem all that elegant)

I'm sure I'll probably get full credit since it works the way it's supposed to, but it bugs me that I couldn't figure out a better solution, even with my prodigious google skills.
Maybe I'm misunderstanding the problem but it sounds like what you want is a sort algorithm. Just put all the scores into an array and sort it. First one will be the lowest
[Probably merge sort but given real world context the input shouldn't bee too huge so some other sort might be more optimal, you could benchmark and switch sorts but that seems like overkill]

At any rate you might want to look at selection sort because the part where it selects the lowest number sounds kind of like your problem.
http://en.wikipedia.org/wiki/Selection_sort

Edit: Meh if you just have to announce best and don't care about anything else. Just assume first score is best (first = lowest), if next is better (current < lowest) that becomes best (lowest = current)...rinse, repeat...O(n).

Last edited by clowntable; 09-16-2014 at 12:04 PM.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-16-2014 , 12:18 PM
Quote:
Originally Posted by jjshabado
Python > Java > C++ >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>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>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>>>>VB
I agree for the most part but with the usual "it depends" modifier. If he's a mathematician the answer might be C/C++ or even Fortran for example. But by and large I'd say Python/Ruby are fine.

There's also people way smarter than me (Linus Torvalds for example) who think VB or Basic in general is excellent to learn programming.

There's always the...well Lisp route. Unfortunately I cannot comment on it but I'd assume a Lisp would make a good first language. In the day of the web I tend to value community support/breadth quite a bit and that's an extra point for Python/Ruby for me.
Java is really strong in that regard (much more so than C++) because it's kind of self feeding since it's used as a starter language in many universities etc.

I kind of want to say consider JavaScript but the browser API is too much of a nightmare. JS is an excellent second language imo, especially once you can appreciate prototype inheritance which is kind of awesome.

Most important thing is always to pick a project you enjoy and build it. It can be silly and dumb but finishing SOMETHING is a strong motivation.
Also don't worry about what IDE to use, if you should write tests, use any maketools etc...just pick randomly if in doubt and crank out code
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-16-2014 , 02:08 PM
Quote:
Originally Posted by clowntable
I agree for the most part but with the usual "it depends" modifier. If he's a mathematician the answer might be C/C++ or even Fortran for example. But by and large I'd say Python/Ruby are fine.
There's always an 'it depends', but TBH, I can't think of many situations where I would recommend C/C++ over Python. Learning to program is more than just learning syntax - and Python is a much easier language to learn. Learning Python then learning C++ seems better in a lot of cases than just going straight to C++. Not sure though.

When I was graduating from University the CS program at my school was having a lot of success with teaching Scheme for the first semester and then moving to Java in the second semester.

Quote:
Originally Posted by clowntable
There's also people way smarter than me (Linus Torvalds for example) who think VB or Basic in general is excellent to learn programming.
Do you have a source? I'd be interested in reading why.

My main objection to VB is that it makes things 'easier'/'simpler' in ways that aren't really useful for learning and that aren't analogous to other languages. Case insensitivity, not short circuiting, ... that's all I can remember it's been awhile since I used it. Plus you still have to deal with things like Visual Studio... not the best learning environment, imo.

Quote:
Originally Posted by clowntable
There's always the...well Lisp route. Unfortunately I cannot comment on it but I'd assume a Lisp would make a good first language.
I TA'd the Scheme course I mentioned above. It was a great introductory CS course.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-16-2014 , 04:55 PM
Quote:
Originally Posted by clowntable
Maybe I'm misunderstanding the problem but it sounds like what you want is a sort algorithm. Just put all the scores into an array and sort it. First one will be the lowest
Perhaps I didn't make clear how much of a beginners class this is. We have in our arsenal loops and if/else statements. That's it. Like a month into class and that's what we have.

Anyway, I got full credit for it doing the clumsy way I did it, but I would be curious to go back and rework it later when we actually touch on arrays and sorting algorithms and such.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-16-2014 , 05:22 PM
It was a pretty cool interview series on Coding Horror iirc (wherethey sent a couple of questions to well known programmers). Good read, should be easy to find via Google.
Edit: nope CR just reposted it:
http://www.dodgycoder.net/2012/09/q-...ogrammers.html

Quote:
For example, I personally believe that "Visual Basic" did more for programming than "Object-Oriented Languages" did. Yet people laugh at VB and say it’s a bad language, and they’ve been talking about OO languages for decades.

And no, Visual Basic wasn’t a great language, but I think the easy DB interfaces in VB were fundmantally more important than object orientation is, for example.
So more of a "not as horrible as people think" but still noteworthy
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-16-2014 , 05:56 PM
I have a small place in my heart for VB, got me into computing tbh. When I was using it in college back in 2002 it let me make Windows programs that with a bit of work looked legit. Getting visual results quickly is a really good way to engage and inspire people imo.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-16-2014 , 07:54 PM
That's fair. I used VB.net for about 3 months and I actually didn't hate it. My concerns are more related to it doing things that aren't common with other languages and not being particularly easy to learn (as compared to a python hello world).
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
09-16-2014 , 11:49 PM
Quote:
Originally Posted by Anais
Perhaps I didn't make clear how much of a beginners class this is. We have in our arsenal loops and if/else statements. That's it. Like a month into class and that's what we have.

Anyway, I got full credit for it doing the clumsy way I did it, but I would be curious to go back and rework it later when we actually touch on arrays and sorting algorithms and such.
Wait, you were trying to find the best golf score right? If you haven't touched on arrays, where on earth do all the golf scores come from?
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD **
$25m Guaranteed WPM on CoinPoker
Join the action now
Daily Rewards • Splash Pots • CoinRaces
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD **

      
m