• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EDT 08:55
CEST 14:55
KST 21:55
  • Home
  • Forum
  • Calendar
  • Streams
  • Liquipedia
  • Features
  • Store
  • EPT
  • TL+
  • StarCraft 2
  • Brood War
  • Smash
  • Heroes
  • Counter-Strike
  • Overwatch
  • Liquibet
  • Fantasy StarCraft
  • TLPD
  • StarCraft 2
  • Brood War
  • Blogs
Forum Sidebar
Events/Features
News
Featured News
Maestros of the Game: Week 1/Play-in Preview12[ASL20] Ro24 Preview Pt2: Take-Off7[ASL20] Ro24 Preview Pt1: Runway132v2 & SC: Evo Complete: Weekend Double Feature4Team Liquid Map Contest #21 - Presented by Monster Energy16
Community News
LiuLi Cup - September 2025 Tournaments2Weekly Cups (August 25-31): Clem's Last Straw?39Weekly Cups (Aug 18-24): herO dethrones MaxPax6Maestros of The Game—$20k event w/ live finals in Paris54Weekly Cups (Aug 11-17): MaxPax triples again!15
StarCraft 2
General
Team Liquid Map Contest #21 - Presented by Monster Energy #1: Maru - Greatest Players of All Time Production Quality - Maestros of the Game Vs RSL 2 Geoff 'iNcontroL' Robinson has passed away Heaven's Balance Suggestions (roast me)
Tourneys
Maestros of The Game—$20k event w/ live finals in Paris RSL: Revival, a new crowdfunded tournament series Chzzk MurlocKing SC1 vs SC2 Cup Sea Duckling Open (Global, Bronze-Diamond) LiuLi Cup - September 2025 Tournaments
Strategy
Custom Maps
External Content
Mutation # 489 Bannable Offense Mutation # 488 What Goes Around Mutation # 487 Think Fast Mutation # 486 Watch the Skies
Brood War
General
The Korean Terminology Thread BGH Auto Balance -> http://bghmmr.eu/ Pros React To: herO's Baffling Game ASL20 General Discussion BW General Discussion
Tourneys
[Megathread] Daily Proleagues [IPSL] ISPL Season 1 Winter Qualis and Info! Is there English video for group selection for ASL Small VOD Thread 2.0
Strategy
Simple Questions, Simple Answers Muta micro map competition Fighting Spirit mining rates [G] Mineral Boosting
Other Games
General Games
General RTS Discussion Thread Stormgate/Frost Giant Megathread Nintendo Switch Thread Path of Exile Warcraft III: The Frozen Throne
Dota 2
Official 'what is Dota anymore' discussion
League of Legends
Heroes of the Storm
Simple Questions, Simple Answers Heroes of the Storm 2.0
Hearthstone
Heroes of StarCraft mini-set
TL Mafia
TL Mafia Community Thread Vanilla Mini Mafia
Community
General
US Politics Mega-thread The Games Industry And ATVI Things Aren’t Peaceful in Palestine Russo-Ukrainian War Thread Canadian Politics Mega-thread
Fan Clubs
The Happy Fan Club!
Media & Entertainment
[Manga] One Piece Anime Discussion Thread Movie Discussion! [\m/] Heavy Metal Thread
Sports
MLB/Baseball 2023 2024 - 2026 Football Thread Formula 1 Discussion TeamLiquid Health and Fitness Initiative For 2023
World Cup 2022
Tech Support
Computer Build, Upgrade & Buying Resource Thread High temperatures on bridge(s)
TL Community
The Automated Ban List TeamLiquid Team Shirt On Sale
Blogs
Collective Intelligence: Tea…
TrAiDoS
A very expensive lesson on ma…
Garnet
hello world
radishsoup
Lemme tell you a thing o…
JoinTheRain
RTS Design in Hypercoven
a11
Evil Gacha Games and the…
ffswowsucks
INDEPENDIENTE LA CTM
XenOsky
Customize Sidebar...

Website Feedback

Closed Threads



Active: 1478 users

The Big Programming Thread - Page 167

Forum Index > General Forum
Post a Reply
Prev 1 165 166 167 168 169 1031 Next
Thread Rules
1. This is not a "do my homework for me" thread. If you have specific questions, ask, but don't post an assignment or homework problem and expect an exact solution.
2. No recruiting for your cockamamie projects (you won't replace facebook with 3 dudes you found on the internet and $20)
3. If you can't articulate why a language is bad, don't start slinging shit about it. Just remember that nothing is worse than making CSS IE6 compatible.
4. Use [code] tags to format code blocks.
Akka
Profile Joined August 2010
France291 Posts
September 15 2012 16:14 GMT
#3321
On September 15 2012 07:32 phar wrote:
Show nested quote +
On September 13 2012 17:11 darmousseh wrote:
Have any of you guys started using NodeJs yet? It looks really exciting. Coming from the ruby on rails world, nodejs looks to me like it's the next Big Thing in the web developer world. What are your guy's thoughts?

If you are looking to write server or backend code, I strongly suggest you use something that is more scalable, and offers better concurrency and performance than NodeJs. While I can appreciate the need for javascript on the frontend, using it elsewhere does not seem like a good idea.


lol, have you actually checked what node.js is about and how it works?

I'd have to agree though that Go seems like it would be worth a try, as is anything coming from Google.

On September 14 2012 21:35 Andin wrote:
What music do you guys like to listen to when you code?


When I have to work late at night, hardstyle is the only thing that keeps me awake... otherwise, anything from 90's pop to various styles of metal or eletronic music.
FFGenerations
Profile Blog Joined April 2011
7088 Posts
September 15 2012 18:41 GMT
#3322
hey programmers

im 28 yrs old and think that its possible for me to become a programmer by homestudy and building a portfolio over the next 3 years. i will not be going to uni or getting a degree as i have to work (random minimum wage stuff). but in 3 years time i hope to get some well-paid job and have a decent future as a programmer.

im going to read this thread, and also have a look on http://www.codecademy.com . after that i guess i will pick a language, like java, and start a tutorial.

my background is: wrote some room descriptions in LPC, went to uni for computer animation/web design but didnt do any of it whatsoever (failed), now 10 yrs later still wondering what to do with my life

so ya, see you in 167 pages
Cool BW Music Vid - youtube.com/watch?v=W54nlqJ-Nx8 ~~~~~ ᕤ OYSTERS ᕤ CLAMS ᕤ AND ᕤ CUCKOLDS ᕤ ~~~~~~ ༼ ᕤ◕◡◕ ༽ᕤ PUNCH HIM ༼ ᕤ◕◡◕ ༽ᕤ
NeMeSiS3
Profile Blog Joined February 2012
Canada2972 Posts
September 15 2012 18:44 GMT
#3323
We just started learning JDK in CS1073 (introduction into programming etc) and we're about 3-4 days in. We've covered really basic things like System.out.println("") or scanners but do you guys have any advice to really get ahead of the learning curve with JDK's? I want to start learning more but I dunno really where to go
FoTG fighting!
phar
Profile Joined August 2011
United States1080 Posts
September 15 2012 19:11 GMT
#3324
Heads up, in case you want to learn functional programming, there's a coursera thingy starting up by the guy who made scala:
https://www.coursera.org/course/progfun

On September 16 2012 03:44 NeMeSiS3 wrote:
We just started learning JDK in CS1073 (introduction into programming etc) and we're about 3-4 days in. We've covered really basic things like System.out.println("") or scanners but do you guys have any advice to really get ahead of the learning curve with JDK's? I want to start learning more but I dunno really where to go

Good start, from the OP:

On July 07 2010 21:59 tofucake wrote:+ Show Spoiler [Java] +

http://download.oracle.com/docs/cd/E17409_01/javase/tutorial/ - credit to mmp (personally, I haven't looked at this yet)
http://www.javabeginner.com/Java-keywords.doc - This is a DOC file, be warned! I haven't looked at it yet, but it apparently covers the basics (things like public, private, etc). Credit to UdderChaos for the link.
http://www.blackbeltfactory.com/ui#! - An annoyingly CPU intensive website made from JAVA for some reason, but it's got a bunch of courses and such about Java programming.

Who after all is today speaking about the destruction of the Armenians?
CoughingHydra
Profile Blog Joined May 2012
177 Posts
Last Edited: 2012-09-15 20:45:53
September 15 2012 19:14 GMT
#3325
On September 16 2012 03:41 FFGenerations wrote:
hey programmers

im 28 yrs old and think that its possible for me to become a programmer by homestudy and building a portfolio over the next 3 years. i will not be going to uni or getting a degree as i have to work (random minimum wage stuff). but in 3 years time i hope to get some well-paid job and have a decent future as a programmer.

im going to read this thread, and also have a look on http://www.codecademy.com . after that i guess i will pick a language, like java, and start a tutorial.

my background is: wrote some room descriptions in LPC, went to uni for computer animation/web design but didnt do any of it whatsoever (failed), now 10 yrs later still wondering what to do with my life

so ya, see you in 167 pages


I think it is definitely possible, but you have to find good literature. I learned C++ while in high school from some random book and often times I found myself not understanding examples because I lacked knowledge from other programming areas (algorithms and data structures) and maths. Also I don't think java is a good starting language, you should go for some procedural language.

EDIT:
You should read the whole OP, there's a lot of useful info in there
billy5000
Profile Blog Joined December 2010
United States865 Posts
Last Edited: 2012-09-17 11:40:47
September 17 2012 11:29 GMT
#3326
On September 16 2012 04:11 phar wrote:
Heads up, in case you want to learn functional programming, there's a coursera thingy starting up by the guy who made scala:
https://www.coursera.org/course/progfun




Thanks for the heads up lol. btw, I finished the first assignment, but it took me like an hour just to set it up. Another 30min to figure out what I'm supposed to do. Then like 10min to implement the methods. All in the course of a couple of days. I've never done anything like this before lol. The main problem was setting up sbt on linux, which I'm also unfamiliar with.

Can someone explain to me what sbt, simple build too, is used for in layman's terms? I kind of remember ant when I was learning java, but I never got around to figuring what it was used for. I'm used to compiling and running programs on the terminal, so maybe someone can explain the benefits of sbt over the terminal? Thanks in advance.
Tiger got to hunt, bird got to fly; Man got to sit and wonder, 'Why, why, why?' Tiger got to sleep, bird got to land; Man got to tell himself he understand. Vonnegut
Frigo
Profile Joined August 2009
Hungary1023 Posts
Last Edited: 2012-09-17 12:20:19
September 17 2012 12:20 GMT
#3327

A Short Lecture On The Value And Practice of Unit Testing

http://www.fimfiction.net/user/Treasure_Chest
Kambing
Profile Joined May 2010
United States1176 Posts
Last Edited: 2012-09-17 12:42:19
September 17 2012 12:41 GMT
#3328
On September 17 2012 20:29 billy5000 wrote:
Show nested quote +
On September 16 2012 04:11 phar wrote:
Heads up, in case you want to learn functional programming, there's a coursera thingy starting up by the guy who made scala:
https://www.coursera.org/course/progfun




Thanks for the heads up lol. btw, I finished the first assignment, but it took me like an hour just to set it up. Another 30min to figure out what I'm supposed to do. Then like 10min to implement the methods. All in the course of a couple of days. I've never done anything like this before lol. The main problem was setting up sbt on linux, which I'm also unfamiliar with.

Can someone explain to me what sbt, simple build too, is used for in layman's terms? I kind of remember ant when I was learning java, but I never got around to figuring what it was used for. I'm used to compiling and running programs on the terminal, so maybe someone can explain the benefits of sbt over the terminal? Thanks in advance.


Sbt is a build tool like ant or makefiles that automates the process of building a project and other related tasks.
Zenithal
Profile Joined August 2011
United States142 Posts
September 19 2012 16:35 GMT
#3329
OK, this is dumb and I should know this, but in HTML, the <div> tag denotes a "block". When you make a <div></div>, and then another one after it, they are aligned vertically on the page, on top of one another. How do I make these horizontal, next to one another?
Whatevs
tofucake
Profile Blog Joined October 2009
Hyrule19083 Posts
Last Edited: 2012-09-19 16:43:25
September 19 2012 16:43 GMT
#3330
float them or use absolute positioning
Liquipediaasante sana squash banana
Deleted User 101379
Profile Blog Joined August 2010
4849 Posts
September 19 2012 16:47 GMT
#3331
On September 20 2012 01:35 Zenithal wrote:
OK, this is dumb and I should know this, but in HTML, the <div> tag denotes a "block". When you make a <div></div>, and then another one after it, they are aligned vertically on the page, on top of one another. How do I make these horizontal, next to one another?


This should do the trick (from memory, not tested, i don't do much HTML stuff since a while):


<div style="float: left; width: 200px; height: 200px; background-color: #00F;">1</div>
<div style="float: left; width: 200px; height: 200px; background-color: #F00;">2</div>
<div style="clear: both; width: 200px; height: 200px; background-color: #0F0;">Zurück zu Normal</div>

supereddie
Profile Joined March 2011
Netherlands151 Posts
September 19 2012 16:50 GMT
#3332
Or just use "display:inline"
"Do not try to make difficult things possible, but make simple things simple." - David Platt on Software Design
loleraserheadz112
Profile Joined January 2011
United States63 Posts
September 20 2012 23:16 GMT
#3333
Hey I need some help with a program that I'm trying to write, its pretty simple so I think someone will be able to help. I'm programming in C++. The basic idea is for the user to enter two points, and the program to respond with a midpoint, as well as account for some user error. This is what it might look like:
+ Show Spoiler +
--------------------------------------------------------------------------------------------------
Where is your first point? 3.4 12.2)

You were missing the open parenthesis before the x coordinate!
You were missing the comma to separate coordinates!

Please use proper notation...

Where is your second point? (13.4, 12.2

You were missing the close parenthesis after the y coordinate!

Please use proper notation...

Thank you!! Calculating... Done.

(3.4, 12.2) is 10 units away from (13.4, 12.2).

The midpoint of the line segment from (3.4, 12.2) to
(13.4, 12.2) is (8.4, 12.2).
-----------------------------------------------------------------

So far this is what i have:
+ Show Spoiler +
--------------------------------------------------------------------
#include <iostream>
using namespace std;
int main (void)

{
cout << "\n\t\tWelcome to the 2D point program!!!\n";
char ptx1, pty1;
int pptx1, ppty1;
cout << "\nWhere is your first point?";
cin >> pptx1, ppty1;
cin.ignore();
if (ptx1 == (pptx1, ppty1)){
cout <<"\n\tYou were missing the open parenthesis before the x coordinate!";
cout <<"\n\tYou were missing the comma to separate coordinates!\n";
cout <<"\n\tPlease use proper notation...\n";
}
else if (ptx1 == ((pptx1,"." ppty1)){
cout <<"\nYou were missing the close parenthesis after the y coordinate!\n"
cout <<"\n\tPlease use proper notation...\n";
cout <<"\nThank you!!! Calculating... Done.";
}
else (ptx1 == ("("pptx1,"," ppty1")");{
cout <<"\nThank you!! Calculating... Done.\n";
}
cout << "\nThank you!! Calculating... Done.\n";
cout << >> ptx1 >> "," >> pty1 >> "is" << << "units away from" << ptx2, pty2 >>".";
cout << "\nThe midpoint of the line segment from" << ptx1 << "." << pty1 >> "to" >>ptx2 >> pty2 >> "is" <<
return 0;
}
----------------------------------------------------------------------------------------


I'm really new to programming so feel free to let me know anything. My program isn't nearly complete, but a push in the right direction would help. Thanks
Insanity is repeating the same task and expecting different results.
weishime
Profile Joined August 2011
65 Posts
September 21 2012 04:31 GMT
#3334
On September 21 2012 08:16 FullAccess wrote:
Hey I need some help with a program that I'm trying to write, its pretty simple so I think someone will be able to help. I'm programming in C++. The basic idea is for the user to enter two points, and the program to respond with a midpoint, as well as account for some user error. This is what it might look like:
+ Show Spoiler +
--------------------------------------------------------------------------------------------------
Where is your first point? 3.4 12.2)

You were missing the open parenthesis before the x coordinate!
You were missing the comma to separate coordinates!

Please use proper notation...

Where is your second point? (13.4, 12.2

You were missing the close parenthesis after the y coordinate!

Please use proper notation...

Thank you!! Calculating... Done.

(3.4, 12.2) is 10 units away from (13.4, 12.2).

The midpoint of the line segment from (3.4, 12.2) to
(13.4, 12.2) is (8.4, 12.2).
-----------------------------------------------------------------

So far this is what i have:
+ Show Spoiler +
--------------------------------------------------------------------
#include <iostream>
using namespace std;
int main (void)

{
cout << "\n\t\tWelcome to the 2D point program!!!\n";
char ptx1, pty1;
int pptx1, ppty1;
cout << "\nWhere is your first point?";
cin >> pptx1, ppty1;
cin.ignore();
if (ptx1 == (pptx1, ppty1)){
cout <<"\n\tYou were missing the open parenthesis before the x coordinate!";
cout <<"\n\tYou were missing the comma to separate coordinates!\n";
cout <<"\n\tPlease use proper notation...\n";
}
else if (ptx1 == ((pptx1,"." ppty1)){
cout <<"\nYou were missing the close parenthesis after the y coordinate!\n"
cout <<"\n\tPlease use proper notation...\n";
cout <<"\nThank you!!! Calculating... Done.";
}
else (ptx1 == ("("pptx1,"," ppty1")");{
cout <<"\nThank you!! Calculating... Done.\n";
}
cout << "\nThank you!! Calculating... Done.\n";
cout << >> ptx1 >> "," >> pty1 >> "is" << << "units away from" << ptx2, pty2 >>".";
cout << "\nThe midpoint of the line segment from" << ptx1 << "." << pty1 >> "to" >>ptx2 >> pty2 >> "is" <<
return 0;
}
----------------------------------------------------------------------------------------


I'm really new to programming so feel free to let me know anything. My program isn't nearly complete, but a push in the right direction would help. Thanks


I'm not a C++ person and just spitballing here since you say you're new.

You want to get point 2 entered before you start calculating. Also you might need a check to make sure they are not the same location. I'm also not sure if you can enter 2 values at once like that with cin. If you can great, if you can't just seperate them.

After that it just seems your result would be (point1 x - point 2x)/2 and (point1y-point2y)/2. That would be the midpoint right? Not sure how it would look at negative numbers.

Past that you might want to look at learning to reuse your code. For instance the code to check point 1 and 2 are valid would be a lot alike so you could learn to call a seperate function and pass the point 1/2 there to check instead. You end up saving a few lines and get to reuse code which is always good. Then you run the calculation and everything looks a little tidier.
CorsairHero
Profile Joined December 2008
Canada9491 Posts
September 21 2012 06:35 GMT
#3335
does anyone have any recommendations for guides on how to start programming android apps using eclipse as well as interfacing with a device connected via mini usb to usb? I don't really know java as I've been focusing on C/C++/C# in my classes.
© Current year.
mmp
Profile Blog Joined April 2009
United States2130 Posts
September 21 2012 06:44 GMT
#3336
On September 21 2012 15:35 CorsairHero wrote:
does anyone have any recommendations for guides on how to start programming android apps using eclipse as well as interfacing with a device connected via mini usb to usb? I don't really know java as I've been focusing on C/C++/C# in my classes.

I would get familiar with Java before diving straight into the Android API. You may get overwhelmed by a lot of the documentation without first getting a handle on JavaDocs and the Java SDK.

Otherwise, http://developer.android.com/training/basics/firstapp/index.html
I (λ (foo) (and (<3 foo) ( T_T foo) (RAGE foo) )) Starcraft
mmp
Profile Blog Joined April 2009
United States2130 Posts
Last Edited: 2012-09-21 06:49:18
September 21 2012 06:49 GMT
#3337
On September 21 2012 08:16 FullAccess wrote:
Hey I need some help with a program that I'm trying to write, its pretty simple so I think someone will be able to help. I'm programming in C++. The basic idea is for the user to enter two points, and the program to respond with a midpoint, as well as account for some user error. This is what it might look like:
+ Show Spoiler +
--------------------------------------------------------------------------------------------------
Where is your first point? 3.4 12.2)

You were missing the open parenthesis before the x coordinate!
You were missing the comma to separate coordinates!

Please use proper notation...

Where is your second point? (13.4, 12.2

You were missing the close parenthesis after the y coordinate!

Please use proper notation...

Thank you!! Calculating... Done.

(3.4, 12.2) is 10 units away from (13.4, 12.2).

The midpoint of the line segment from (3.4, 12.2) to
(13.4, 12.2) is (8.4, 12.2).
-----------------------------------------------------------------

So far this is what i have:
+ Show Spoiler +
--------------------------------------------------------------------
#include <iostream>
using namespace std;
int main (void)

{
cout << "\n\t\tWelcome to the 2D point program!!!\n";
char ptx1, pty1;
int pptx1, ppty1;
cout << "\nWhere is your first point?";
cin >> pptx1, ppty1;
cin.ignore();
if (ptx1 == (pptx1, ppty1)){
cout <<"\n\tYou were missing the open parenthesis before the x coordinate!";
cout <<"\n\tYou were missing the comma to separate coordinates!\n";
cout <<"\n\tPlease use proper notation...\n";
}
else if (ptx1 == ((pptx1,"." ppty1)){
cout <<"\nYou were missing the close parenthesis after the y coordinate!\n"
cout <<"\n\tPlease use proper notation...\n";
cout <<"\nThank you!!! Calculating... Done.";
}
else (ptx1 == ("("pptx1,"," ppty1")");{
cout <<"\nThank you!! Calculating... Done.\n";
}
cout << "\nThank you!! Calculating... Done.\n";
cout << >> ptx1 >> "," >> pty1 >> "is" << << "units away from" << ptx2, pty2 >>".";
cout << "\nThe midpoint of the line segment from" << ptx1 << "." << pty1 >> "to" >>ptx2 >> pty2 >> "is" <<
return 0;
}
----------------------------------------------------------------------------------------


I'm really new to programming so feel free to let me know anything. My program isn't nearly complete, but a push in the right direction would help. Thanks


What you're doing intuitively with parentheses and strings turns out to be very incorrect syntax. Read up on strings, character arrays, and pointers / dereferencing.

+ Show Spoiler +
If you need a hint, look into the scanf function to help parse input.
I (λ (foo) (and (<3 foo) ( T_T foo) (RAGE foo) )) Starcraft
Akka
Profile Joined August 2010
France291 Posts
September 24 2012 04:58 GMT
#3338
On September 21 2012 15:49 mmp wrote:
Show nested quote +
On September 21 2012 08:16 FullAccess wrote:
Hey I need some help with a program that I'm trying to write, its pretty simple so I think someone will be able to help. I'm programming in C++. The basic idea is for the user to enter two points, and the program to respond with a midpoint, as well as account for some user error. This is what it might look like:
+ Show Spoiler +
--------------------------------------------------------------------------------------------------
Where is your first point? 3.4 12.2)

You were missing the open parenthesis before the x coordinate!
You were missing the comma to separate coordinates!

Please use proper notation...

Where is your second point? (13.4, 12.2

You were missing the close parenthesis after the y coordinate!

Please use proper notation...

Thank you!! Calculating... Done.

(3.4, 12.2) is 10 units away from (13.4, 12.2).

The midpoint of the line segment from (3.4, 12.2) to
(13.4, 12.2) is (8.4, 12.2).
-----------------------------------------------------------------

So far this is what i have:
+ Show Spoiler +
--------------------------------------------------------------------
#include <iostream>
using namespace std;
int main (void)

{
cout << "\n\t\tWelcome to the 2D point program!!!\n";
char ptx1, pty1;
int pptx1, ppty1;
cout << "\nWhere is your first point?";
cin >> pptx1, ppty1;
cin.ignore();
if (ptx1 == (pptx1, ppty1)){
cout <<"\n\tYou were missing the open parenthesis before the x coordinate!";
cout <<"\n\tYou were missing the comma to separate coordinates!\n";
cout <<"\n\tPlease use proper notation...\n";
}
else if (ptx1 == ((pptx1,"." ppty1)){
cout <<"\nYou were missing the close parenthesis after the y coordinate!\n"
cout <<"\n\tPlease use proper notation...\n";
cout <<"\nThank you!!! Calculating... Done.";
}
else (ptx1 == ("("pptx1,"," ppty1")");{
cout <<"\nThank you!! Calculating... Done.\n";
}
cout << "\nThank you!! Calculating... Done.\n";
cout << >> ptx1 >> "," >> pty1 >> "is" << << "units away from" << ptx2, pty2 >>".";
cout << "\nThe midpoint of the line segment from" << ptx1 << "." << pty1 >> "to" >>ptx2 >> pty2 >> "is" <<
return 0;
}
----------------------------------------------------------------------------------------


I'm really new to programming so feel free to let me know anything. My program isn't nearly complete, but a push in the right direction would help. Thanks


What you're doing intuitively with parentheses and strings turns out to be very incorrect syntax. Read up on strings, character arrays, and pointers / dereferencing.

+ Show Spoiler +
If you need a hint, look into the scanf function to help parse input.



Do NOT use cstdlib/cstdio functions in C++ unless you have a very good reason for doing so.

If you want to get user input, just use iostream's std::cin ( http://cplusplus.com/reference/iostream/ ) to get a whole line and parse it with a couple of calls to std::string's member functions. If you want to convert a string to an int : http://www.cplusplus.com/articles/D9j2Nwbp/

Also, use std::endl to put a '\n' at the end of your stream

Finally, do NOT use "using namespace xxx". Bad practice for now, and it won't slow you down to write std:: a couple of times.
Warrior Madness
Profile Blog Joined April 2008
Canada3791 Posts
Last Edited: 2012-09-24 05:26:16
September 24 2012 05:12 GMT
#3339
Really cool thread! I wonder if there are any TLers that work at google?

Came from reading this blog on bad agile vs good:
http://steve-yegge.blogspot.ca/search?q=google

Also an equally fascinating read on the google interview process. The blogger happens to be a google interviewer.:
http://steve-yegge.blogspot.ca/2008/03/get-that-job-at-google.html
The Past: Yellow, Julyzerg, Chojja, Savior, GGplay -- The Present: Luxury, Jae- The Future: -Dong, maGma, Zero, Effort, Hoejja, hyvaa, by.hero, calm, Action ---> SC2 (Ret?? Kolll Idra!! SEN, Cool, ZergBong, Leenock)
darmousseh
Profile Blog Joined May 2010
United States3437 Posts
September 24 2012 07:16 GMT
#3340
On September 15 2012 07:32 phar wrote:
Show nested quote +
On September 13 2012 17:11 darmousseh wrote:
Have any of you guys started using NodeJs yet? It looks really exciting. Coming from the ruby on rails world, nodejs looks to me like it's the next Big Thing in the web developer world. What are your guy's thoughts?

If you are looking to write server or backend code, I strongly suggest you use something that is more scalable, and offers better concurrency and performance than NodeJs. While I can appreciate the need for javascript on the frontend, using it elsewhere does not seem like a good idea.

If you want to use something new and shiny, I suppose you could take a look at Go. There'll be a bit of a learning curve to get used to the syntax & style if you're coming from a js/RoR background, but it'd be worth it in the end.

NodeJs will certainly be easier for you if you're used to ruby on rails, so if you're just messing around with personal projects, it'll work just fine.


I'm not really worried about learning curve. I've learned about 10 different languages by now, it's more that I think nodejs could eventually replace ruby on rails as the standard in modern web development for startups. I've been playing around with express.js which is a sinatra like application for node and it feels like it's going somewhere.

My current jobs is in rails and I know it's going to be around for a while, but with all of the front end focused web development, I don't see a reason to not use google's V8 virtual machine on the backend. It is single threaded, allows event driven code (to handle more simultaneous requests) and I get to write code that works on the browser and in the backend. As server applications become increasingly api based (mearly xml/json responses), the amount of code on the backend will be small enough that we won't want a huge framework. I already use backbone for the frontend and it's working out great.


Anyway, what frameworks (not languages) do you think will become popular in the next 5 years?
Developer for http://mtgfiddle.com
Prev 1 165 166 167 168 169 1031 Next
Please log in or register to reply.
Live Events Refresh
RSL Revival
10:00
Season 2: Group A
Bunny vs ZounLIVE!
Creator vs TBD
Crank 1225
Tasteless976
IndyStarCraft 222
Rex145
3DClanTV 51
LiquipediaDiscussion
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
Crank 1234
Tasteless 976
IndyStarCraft 230
Rex 145
ProTech111
Codebar 22
Railgan 10
StarCraft: Brood War
Shuttle 1742
firebathero 574
Larva 545
sSak 511
ggaemo 374
Light 274
Last 258
Pusan 247
Zeus 238
JulyZerg 218
[ Show more ]
ToSsGirL 197
Hyuk 183
TY 88
Hyun 78
scan(afreeca) 51
Sea.KH 51
Aegong 50
Free 41
JYJ34
Movie 25
Noble 19
Icarus 17
Terrorterran 10
Shine 8
Hm[arnc] 6
Britney 0
Dota 2
The International84744
Gorgc15298
Fuzer 368
XcaliburYe155
Dendi107
Counter-Strike
zeus293
byalli271
Super Smash Bros
Mew2King55
Heroes of the Storm
Liquid`Hasu251
Khaldor203
Other Games
singsing1504
B2W.Neo1140
DeMusliM444
JimRising 343
Hui .240
Sick191
MindelVK39
Organizations
StarCraft 2
angryscii 1
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 13 non-featured ]
StarCraft 2
• Adnapsc2 5
• AfreecaTV YouTube
• intothetv
• Kozan
• IndyKCrew
• LaughNgamezSOOP
• Migwel
• sooper7s
StarCraft: Brood War
• BSLYoutube
• STPLYoutube
• ZZZeroYoutube
Dota 2
• WagamamaTV239
League of Legends
• Jankos1142
Upcoming Events
Maestros of the Game
4h 5m
Maru vs Lambo
herO vs ShoWTimE
BSL Team Wars
6h 5m
Team Hawk vs Team Sziky
Sparkling Tuna Cup
21h 5m
Monday Night Weeklies
1d 3h
The PondCast
3 days
RSL Revival
3 days
RSL Revival
4 days
Online Event
4 days
BSL Team Wars
5 days
Team Bonyth vs Team Dewalt
BSL Team Wars
5 days
[ Show More ]
RSL Revival
5 days
Maestros of the Game
6 days
Cosmonarchy
6 days
Bonyth vs Dewalt
[BSL 2025] Weekly
6 days
RSL Revival
6 days
Liquipedia Results

Completed

Proleague 2025-09-02
SEL Season 2 Championship
HCC Europe

Ongoing

Copa Latinoamericana 4
BSL 20 Team Wars
KCM Race Survival 2025 Season 3
BSL 21: BSL Points
ASL Season 20
CSL 2025 AUTUMN (S18)
LASL Season 20
RSL Revival: Season 2
Maestros of the Game
Chzzk MurlocKing SC1 vs SC2 Cup #2
BLAST Open Fall 2025
BLAST Open Fall Qual
Esports World Cup 2025
BLAST Bounty Fall 2025
BLAST Bounty Fall Qual
IEM Cologne 2025
FISSURE Playground #1

Upcoming

2025 Chongqing Offline CUP
BSL Polish World Championship 2025
BSL Season 21
BSL 21 Team A
EC S1
BLAST Rivals Fall 2025
IEM Chengdu 2025
PGL Masters Bucharest 2025
Thunderpick World Champ.
MESA Nomadic Masters Fall
CS Asia Championships 2025
ESL Pro League S22
StarSeries Fall 2025
FISSURE Playground #2
TLPD

1. ByuN
2. TY
3. Dark
4. Solar
5. Stats
6. Nerchio
7. sOs
8. soO
9. INnoVation
10. Elazer
1. Rain
2. Flash
3. EffOrt
4. Last
5. Bisu
6. Soulkey
7. Mini
8. Sharp
Sidebar Settings...

Advertising | Privacy Policy | Terms Of Use | Contact Us

Original banner artwork: Jim Warren
The contents of this webpage are copyright © 2025 TLnet. All Rights Reserved.