• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EST 00:02
CET 06:02
KST 14:02
  • 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
ByuL: The Forgotten Master of ZvT24Behind the Blue - Team Liquid History Book16Clem wins HomeStory Cup 289HomeStory Cup 28 - Info & Preview13Rongyi Cup S3 - Preview & Info8
Community News
Weekly Cups (Feb 9-15): herO doubles up2ACS replaced by "ASL Season Open" - Starts 21/0226LiuLi Cup: 2025 Grand Finals (Feb 10-16)46Weekly Cups (Feb 2-8): Classic, Solar, MaxPax win2Nexon's StarCraft game could be FPS, led by UMS maker16
StarCraft 2
General
ByuL: The Forgotten Master of ZvT Kaelaris on the futue of SC2 and much more... How do you think the 5.0.15 balance patch (Oct 2025) for StarCraft II has affected the game? Nexon's StarCraft game could be FPS, led by UMS maker Weekly Cups (Feb 9-15): herO doubles up
Tourneys
PIG STY FESTIVAL 7.0! (19 Feb - 1 Mar) How do the "codes" work in GSL? Sparkling Tuna Cup - Weekly Open Tournament LiuLi Cup: 2025 Grand Finals (Feb 10-16) Master Swan Open (Global Bronze-Master 2)
Strategy
Custom Maps
Map Editor closed ? [A] Starcraft Sound Mod
External Content
Mutation # 513 Attrition Warfare The PondCast: SC2 News & Results Mutation # 512 Overclocked Mutation # 511 Temple of Rebirth
Brood War
General
TvZ is the most complete match up A new season just kicks off BGH Auto Balance -> http://bghmmr.eu/ ACS replaced by "ASL Season Open" - Starts 21/02 [ASL21] Potential Map Candidates
Tourneys
Small VOD Thread 2.0 [Megathread] Daily Proleagues Escore Tournament StarCraft Season 1 KCM Race Survival 2026 Season 1
Strategy
Simple Questions, Simple Answers Fighting Spirit mining rates Zealot bombing is no longer popular? Current Meta
Other Games
General Games
ZeroSpace Megathread Nintendo Switch Thread Path of Exile Diablo 2 thread Battle Aces/David Kim RTS Megathread
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
Deck construction bug Heroes of StarCraft mini-set
TL Mafia
Vanilla Mini Mafia TL Mafia Community Thread Mafia Game Mode Feedback/Ideas
Community
General
US Politics Mega-thread Canadian Politics Mega-thread Russo-Ukrainian War Thread Ask and answer stupid questions here! Things Aren’t Peaceful in Palestine
Fan Clubs
The IdrA Fan Club The herO Fan Club!
Media & Entertainment
[Req][Books] Good Fantasy/SciFi books [Manga] One Piece Anime Discussion Thread
Sports
2024 - 2026 Football Thread Formula 1 Discussion TL MMA Pick'em Pool 2013
World Cup 2022
Tech Support
TL Community
The Automated Ban List
Blogs
Inside the Communication of …
TrAiDoS
My 2025 Magic: The Gathering…
DARKING
Life Update and thoughts.
FuDDx
How do archons sleep?
8882
Customize Sidebar...

Website Feedback

Closed Threads



Active: 2015 users

The Big Programming Thread - Page 287

Forum Index > General Forum
Post a Reply
Prev 1 285 286 287 288 289 1032 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.
nunez
Profile Blog Joined February 2011
Norway4003 Posts
Last Edited: 2013-04-21 19:57:27
April 21 2013 19:55 GMT
#5721
edit: might be wrong.
conspired against by a confederacy of dunces.
iaretehnoob
Profile Joined June 2004
Sweden741 Posts
April 21 2013 20:11 GMT
#5722
On April 22 2013 04:41 Arnstein wrote:
I need help with something:

In a class, I have to make an add function that takes in another instance of that class, and iterate over a private member of that function, a map that takes in two string arguments. Then I have to iterate over the first string argument, and add both to the existing one. This doesn't work:
+ Show Spoiler +

void add ( const PhonebookEntry& copyFrom ) 
{
for ( map<string, string>::iterator itty = this->numbers.begin() ; itty != this->numbers.end() ; itty++ )
{
}

}



What is the correct way to iterate over this?

Define "This doesn't work". What is the error?
Also while the rest of the question is not really clear to me, I think you want to iterate over copyFrom.numbers, not this->numbers.
Better yet: look at map::insert().
Arnstein
Profile Blog Joined May 2010
Norway3381 Posts
Last Edited: 2013-04-21 20:17:48
April 21 2013 20:15 GMT
#5723
On April 22 2013 05:11 iaretehnoob wrote:
Show nested quote +
On April 22 2013 04:41 Arnstein wrote:
I need help with something:

In a class, I have to make an add function that takes in another instance of that class, and iterate over a private member of that function, a map that takes in two string arguments. Then I have to iterate over the first string argument, and add both to the existing one. This doesn't work:
+ Show Spoiler +

void add ( const PhonebookEntry& copyFrom ) 
{
for ( map<string, string>::iterator itty = this->numbers.begin() ; itty != this->numbers.end() ; itty++ )
{
}

}



What is the correct way to iterate over this?

Define "This doesn't work". What is the error?
Also while the rest of the question is not really clear to me, I think you want to iterate over copyFrom.numbers, not this->numbers.
Better yet: look at map::insert().


I think I want to iterate over the old one, not the copyFrom. This is because you have to replace the old ones, but come to think about it, it's probably just better to iterate over the new one, then insert from it, and delete the ones left on the this->numbers.
The error I get is: invalid use of this outside of a nonstatic member function.

Edit:
If I iterate over the copyFrom, I will probably have to make a get-function for the map. This isn't mentioned in the task text, so I don't think that's the idea.
rsol in response to the dragoon voice being heard in SCII: dragoon ai reaches new lows: wanders into wrong game
iaretehnoob
Profile Joined June 2004
Sweden741 Posts
April 21 2013 20:29 GMT
#5724
I guess your function definition is in a .cpp file and you're missing the class identifier before the function name.
As in:
void PhonebookEntry::add(....) { } 

As for the logic, well, I don't know what you're trying to do, so I'll leave you to it, especially if it's HW.
tuho12345
Profile Blog Joined July 2011
4482 Posts
April 21 2013 20:43 GMT
#5725
hi everyone, I have an internship opportunity coming up, however I have to prepare some basic knowledge on MS SQL. I've read SQL for dummies but could anyone kind to guide me what else I can prepare and tutor or test me a little in the future? Thank you so much
Craton
Profile Blog Joined December 2009
United States17278 Posts
April 21 2013 20:45 GMT
#5726
Think of something to do and write queries that accomplish it.
twitch.tv/cratonz
Isualin
Profile Joined March 2011
Germany1903 Posts
April 21 2013 21:13 GMT
#5727
On April 22 2013 05:43 tuho12345 wrote:
hi everyone, I have an internship opportunity coming up, however I have to prepare some basic knowledge on MS SQL. I've read SQL for dummies but could anyone kind to guide me what else I can prepare and tutor or test me a little in the future? Thank you so much

i think you should find a sample database with a lot of data(like adventureworks) and try sql queries on it if you are inexperienced like me.
| INnoVation | The literal god TY | ByuNjwa | LRSL when? |
Deleted User 101379
Profile Blog Joined August 2010
4849 Posts
April 21 2013 22:58 GMT
#5728
On April 22 2013 05:43 tuho12345 wrote:
hi everyone, I have an internship opportunity coming up, however I have to prepare some basic knowledge on MS SQL. I've read SQL for dummies but could anyone kind to guide me what else I can prepare and tutor or test me a little in the future? Thank you so much


Just remember that MS SQL is different to MySQL.
The MS SQL (or rather SQL Server as it's called by MS) SQL dialect is T-SQL. There are some important differences to the MySQL dialect so be very careful when googling.

For something to program using the SQL Server, a simple blog or CMS should be easy enough but still complex enough to not be completely trivial.
Nazza
Profile Blog Joined August 2010
Australia1654 Posts
April 21 2013 23:20 GMT
#5729
On April 21 2013 11:02 obesechicken13 wrote:
Show nested quote +
On April 21 2013 09:33 Morfildur wrote:
On April 21 2013 08:29 obesechicken13 wrote:
On April 20 2013 01:41 betaflame wrote:
Anyone have experience with PHP simple HTML DOM Parser? I am trying to parse a url and extract an img src from one of the headers.

EDIT: Figured it out!! But I am just wondering if anyone has any idea about the differences/pros/cons of simple HTML DOM Parser vs the built in DOM libraries.

Not sure what the difference is between a dom parser and library is. I thought someone else would have experience with this.


I'm watching a speeding up joomla webinar right now.
In an effort to be more social, I'll post the link here
+ Show Spoiler +

How do I make a site better? Faster? With the joomla framework? I feel like it's just going to be telling me to use cloudflare and optimize the site by removing debugging / unused features / buying more hosting.
Oh god it's so boring... But I learned you can have binary versions of PHP files so that when people access them they don't have to be recompiled every time. I now wonder if this is done automatically by web service providers.


There are many ways to make a site faster. However, 90% of those ways cost more in man hours than just buying another server, so in reality noone cares if your site only has 80% of the possible performance. Readable and maintainable code is usually fast enough that only very few usecases require you to do performance optimization.

Both good points. Developer time is very valuable imo and so it should be used in the most useful ways.

Optimization isn't worth the time for many sites.

Right now I'm going into a course for interactive programming for python on Coursera. I was always confused by how Coursera would make any revenue. They recently added certificates though $45 each I think... Also some of these companies trying to add certification use webcams to monitor test taking and others rent out test centers.


Coursera's pretty awesome. I don't think they expect to make too much money, as I think their main goals are just providing higher education to those that can't really afford it, or just giving access to as many people as they can. I'm about to finish a Python course called "Crafting quality code". It was pretty basic but I learned some things. Still taking a course in Scala, Hardware/Software Interface, and about to start one on machine learning. There's going to be Systematic Program design in a month too.
No one ever remembers second place, eh? eh? GIVE ME COMMAND
obesechicken13
Profile Blog Joined July 2008
United States10467 Posts
April 22 2013 01:20 GMT
#5730
On April 22 2013 08:20 Nazza wrote:
Show nested quote +
On April 21 2013 11:02 obesechicken13 wrote:
On April 21 2013 09:33 Morfildur wrote:
On April 21 2013 08:29 obesechicken13 wrote:
On April 20 2013 01:41 betaflame wrote:
Anyone have experience with PHP simple HTML DOM Parser? I am trying to parse a url and extract an img src from one of the headers.

EDIT: Figured it out!! But I am just wondering if anyone has any idea about the differences/pros/cons of simple HTML DOM Parser vs the built in DOM libraries.

Not sure what the difference is between a dom parser and library is. I thought someone else would have experience with this.


I'm watching a speeding up joomla webinar right now.
In an effort to be more social, I'll post the link here
+ Show Spoiler +
http://www.youtube.com/watch?v=s3gwwcahnkA&feature=youtu.be

How do I make a site better? Faster? With the joomla framework? I feel like it's just going to be telling me to use cloudflare and optimize the site by removing debugging / unused features / buying more hosting.
Oh god it's so boring... But I learned you can have binary versions of PHP files so that when people access them they don't have to be recompiled every time. I now wonder if this is done automatically by web service providers.


There are many ways to make a site faster. However, 90% of those ways cost more in man hours than just buying another server, so in reality noone cares if your site only has 80% of the possible performance. Readable and maintainable code is usually fast enough that only very few usecases require you to do performance optimization.

Both good points. Developer time is very valuable imo and so it should be used in the most useful ways.

Optimization isn't worth the time for many sites.

Right now I'm going into a course for interactive programming for python on Coursera. I was always confused by how Coursera would make any revenue. They recently added certificates though $45 each I think... Also some of these companies trying to add certification use webcams to monitor test taking and others rent out test centers.


Coursera's pretty awesome. I don't think they expect to make too much money, as I think their main goals are just providing higher education to those that can't really afford it, or just giving access to as many people as they can. I'm about to finish a Python course called "Crafting quality code". It was pretty basic but I learned some things. Still taking a course in Scala, Hardware/Software Interface, and about to start one on machine learning. There's going to be Systematic Program design in a month too.

I'm starting to dislike coursera again. I hate formal courses. I was able to do a project today: a rock paper scissors lizard spock game, but I didn't like having to watch video lectures.
I think in our modern age technology has evolved to become more addictive. The things that don't give us pleasure aren't used as much. Work was never meant to be fun, but doing it makes us happier in the long run.
tuho12345
Profile Blog Joined July 2011
4482 Posts
April 22 2013 06:40 GMT
#5731
can anyone with Java skill help me with my particular problem? Please pm me I'll explain more.
Nazza
Profile Blog Joined August 2010
Australia1654 Posts
April 22 2013 08:05 GMT
#5732
On April 22 2013 10:20 obesechicken13 wrote:
Show nested quote +
On April 22 2013 08:20 Nazza wrote:
On April 21 2013 11:02 obesechicken13 wrote:
On April 21 2013 09:33 Morfildur wrote:
On April 21 2013 08:29 obesechicken13 wrote:
On April 20 2013 01:41 betaflame wrote:
Anyone have experience with PHP simple HTML DOM Parser? I am trying to parse a url and extract an img src from one of the headers.

EDIT: Figured it out!! But I am just wondering if anyone has any idea about the differences/pros/cons of simple HTML DOM Parser vs the built in DOM libraries.

Not sure what the difference is between a dom parser and library is. I thought someone else would have experience with this.


I'm watching a speeding up joomla webinar right now.
In an effort to be more social, I'll post the link here
+ Show Spoiler +
http://www.youtube.com/watch?v=s3gwwcahnkA&feature=youtu.be

How do I make a site better? Faster? With the joomla framework? I feel like it's just going to be telling me to use cloudflare and optimize the site by removing debugging / unused features / buying more hosting.
Oh god it's so boring... But I learned you can have binary versions of PHP files so that when people access them they don't have to be recompiled every time. I now wonder if this is done automatically by web service providers.


There are many ways to make a site faster. However, 90% of those ways cost more in man hours than just buying another server, so in reality noone cares if your site only has 80% of the possible performance. Readable and maintainable code is usually fast enough that only very few usecases require you to do performance optimization.

Both good points. Developer time is very valuable imo and so it should be used in the most useful ways.

Optimization isn't worth the time for many sites.

Right now I'm going into a course for interactive programming for python on Coursera. I was always confused by how Coursera would make any revenue. They recently added certificates though $45 each I think... Also some of these companies trying to add certification use webcams to monitor test taking and others rent out test centers.


Coursera's pretty awesome. I don't think they expect to make too much money, as I think their main goals are just providing higher education to those that can't really afford it, or just giving access to as many people as they can. I'm about to finish a Python course called "Crafting quality code". It was pretty basic but I learned some things. Still taking a course in Scala, Hardware/Software Interface, and about to start one on machine learning. There's going to be Systematic Program design in a month too.

I'm starting to dislike coursera again. I hate formal courses. I was able to do a project today: a rock paper scissors lizard spock game, but I didn't like having to watch video lectures.


The whole point of having lectures in that format is that you do projects and assignments, and that there is pressure on you to do them on the deadline. Otherwise, people don't learn, or won't be motivated to do stuff .

Some video lecturers are better than others, but frankly, as long as they speak proper English I don't really care.
No one ever remembers second place, eh? eh? GIVE ME COMMAND
icystorage
Profile Blog Joined November 2008
Jollibee19350 Posts
April 22 2013 13:19 GMT
#5733
is somebody knowledgeable on how neural networks works here? can I send you a PM? specifically feed forward neural networks.
LiquidDota StaffAre you ready for a Miracle-? We are! The International 2017 Champions!
obesechicken13
Profile Blog Joined July 2008
United States10467 Posts
April 22 2013 13:45 GMT
#5734
On April 22 2013 22:19 icystorage wrote:
is somebody knowledgeable on how neural networks works here? can I send you a PM? specifically feed forward neural networks.

Why not just post it here?
I think in our modern age technology has evolved to become more addictive. The things that don't give us pleasure aren't used as much. Work was never meant to be fun, but doing it makes us happier in the long run.
icystorage
Profile Blog Joined November 2008
Jollibee19350 Posts
April 22 2013 14:25 GMT
#5735
i kinda feel these are basic questions and i just need someone to explain them to me :x i watched some videos and read about it but i need someone to answer my questions
LiquidDota StaffAre you ready for a Miracle-? We are! The International 2017 Champions!
AmericanUmlaut
Profile Blog Joined November 2010
Germany2592 Posts
April 22 2013 14:28 GMT
#5736
On April 22 2013 23:25 icystorage wrote:
i kinda feel these are basic questions and i just need someone to explain them to me :x i watched some videos and read about it but i need someone to answer my questions

So why don't you post them here? There's no rule against basic questions.
The frumious Bandersnatch
icystorage
Profile Blog Joined November 2008
Jollibee19350 Posts
April 22 2013 14:39 GMT
#5737
Um okay

1) you can use neural networks to predict an output right?
2) how do you make it predict? do you have to train it?
3) by training it, it adjusts its weight right?
4) if i give NN a pattern of 1,1,1,1,1 will it predict the next number will be 1?
5) heres my general understanding in predicting neural networks
- train the network by feeding it data (it adjusts its weight and compares its output to your EXPECTED, not predicted, output)
- with the current configuration of the weights you now use it to get the predicted output

sorry if its confusing but im also very confused atm
LiquidDota StaffAre you ready for a Miracle-? We are! The International 2017 Champions!
nunez
Profile Blog Joined February 2011
Norway4003 Posts
April 22 2013 14:43 GMT
#5738
does anyone know some good reading material on lexical analysis?
need to buff my skills for summer job.
conspired against by a confederacy of dunces.
mcc
Profile Joined October 2010
Czech Republic4646 Posts
April 22 2013 15:18 GMT
#5739
On April 22 2013 23:39 icystorage wrote:
Um okay

1) you can use neural networks to predict an output right?
2) how do you make it predict? do you have to train it?
3) by training it, it adjusts its weight right?
4) if i give NN a pattern of 1,1,1,1,1 will it predict the next number will be 1?
5) heres my general understanding in predicting neural networks
- train the network by feeding it data (it adjusts its weight and compares its output to your EXPECTED, not predicted, output)
- with the current configuration of the weights you now use it to get the predicted output

sorry if its confusing but im also very confused atm

1) yes
2) You can either train it or set the weights "correctly" at the start by using some other process (but you can also call it training)
3) yes
4) Not necessarily. It depends on what patterns you trained it to recognize and also how well you trained it


Note that there is plenty of NN types and they have sometimes quite different ways of setting up weights. So you need to specify which type you are talking about, most likely some perceptron-like multi-layer network with backpropagation ?
icystorage
Profile Blog Joined November 2008
Jollibee19350 Posts
April 22 2013 16:40 GMT
#5740
@mcc

im actually working on the perceptron-like multi-layer network with backpropagation and im kinda relieved it matched your suggestion (means im on the right track)

what im trying to do is use NN to predict stock prices (yes it is impossible but i want to test the NN with these data)
stock has 4 prices, open, low, high and close. i want it to predict the closing price. now, is the training (weight adjustment) separate from the predicting or should i input all the necessary data (technicalities aside, just the procedure) then expect the predicted value?
LiquidDota StaffAre you ready for a Miracle-? We are! The International 2017 Champions!
Prev 1 285 286 287 288 289 1032 Next
Please log in or register to reply.
Live Events Refresh
Next event in 3h 58m
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
NeuroSwarm 281
ProTech138
StarCraft: Brood War
Zeus 484
ZergMaN 227
Tasteless 99
Bale 22
Icarus 7
League of Legends
JimRising 701
Counter-Strike
Coldzera 1767
taco 419
Heroes of the Storm
Khaldor118
Other Games
summit1g7151
C9.Mang0571
RuFF_SC2186
WinterStarcraft85
Hui .83
Trikslyr36
Organizations
Other Games
gamesdonequick951
StarCraft 2
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 14 non-featured ]
StarCraft 2
• davetesta53
• AfreecaTV YouTube
• intothetv
• Kozan
• IndyKCrew
• LaughNgamezSOOP
• Migwel
• sooper7s
StarCraft: Brood War
• BSLYoutube
• STPLYoutube
• ZZZeroYoutube
League of Legends
• Scarra1252
• Lourlo849
• Stunt339
Upcoming Events
PiG Sty Festival
3h 58m
Clem vs Percival
Zoun vs Solar
Escore
4h 58m
Epic.LAN
6h 58m
Replay Cast
18h 58m
PiG Sty Festival
1d 3h
herO vs NightMare
Reynor vs Cure
CranKy Ducklings
1d 4h
Epic.LAN
1d 6h
Replay Cast
1d 18h
PiG Sty Festival
2 days
Serral vs YoungYakov
ByuN vs ShoWTimE
Sparkling Tuna Cup
2 days
[ Show More ]
Replay Cast
2 days
Replay Cast
3 days
Wardi Open
3 days
Monday Night Weeklies
3 days
Replay Cast
3 days
WardiTV Winter Champion…
4 days
Replay Cast
5 days
WardiTV Winter Champion…
5 days
The PondCast
6 days
Replay Cast
6 days
Liquipedia Results

Completed

Proleague 2026-02-18
LiuLi Cup: 2025 Grand Finals
Underdog Cup #3

Ongoing

KCM Race Survival 2026 Season 1
Escore Tournament S1: King of Kings
WardiTV Winter 2026
PiG Sty Festival 7.0
Nations Cup 2026
PGL Cluj-Napoca 2026
IEM Kraków 2026
BLAST Bounty Winter 2026
BLAST Bounty Winter Qual
eXTREMESLAND 2025
SL Budapest Major 2025

Upcoming

[S:21] ASL SEASON OPEN 1st Round
[S:21] ASL SEASON OPEN 1st Round Qualifier
Acropolis #4 - TS5
Jeongseon Sooper Cup
Spring Cup 2026: China & Korea Invitational
[S:21] ASL SEASON OPEN 2nd Round
[S:21] ASL SEASON OPEN 2nd Round Qualifier
HSC XXIX
uThermal 2v2 2026 Main Event
Bellum Gens Elite Stara Zagora 2026
RSL Revival: Season 4
BLAST Rivals Spring 2026
CCT Season 3 Global Finals
FISSURE Playground #3
IEM Rio 2026
PGL Bucharest 2026
Stake Ranked Episode 1
BLAST Open Spring 2026
ESL Pro League Season 23
ESL Pro League Season 23
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 © 2026 TLnet. All Rights Reserved.