• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EST 22:36
CET 04:36
KST 12:36
  • 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
Behind the Blue - Team Liquid History Book15Clem wins HomeStory Cup 289HomeStory Cup 28 - Info & Preview13Rongyi Cup S3 - Preview & Info8herO wins SC2 All-Star Invitational14
Community News
ACS replaced by "ASL Season Open" - Starts 21/0220LiuLi Cup: 2025 Grand Finals (Feb 10-16)26Weekly Cups (Feb 2-8): Classic, Solar, MaxPax win2Nexon's StarCraft game could be FPS, led by UMS maker10PIG STY FESTIVAL 7.0! (19 Feb - 1 Mar)14
StarCraft 2
General
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 Terran Scanner Sweep Behind the Blue - Team Liquid History Book Weekly Cups (Jan 12-18): herO, MaxPax, Solar win
Tourneys
PIG STY FESTIVAL 7.0! (19 Feb - 1 Mar) LiuLi Cup: 2025 Grand Finals (Feb 10-16) RSL Season 4 announced for March-April RSL Revival: Season 4 Korea Qualifier (Feb 14) Sparkling Tuna Cup - Weekly Open Tournament
Strategy
Custom Maps
Map Editor closed ? [A] Starcraft Sound Mod
External Content
The PondCast: SC2 News & Results Mutation # 512 Overclocked Mutation # 511 Temple of Rebirth Mutation # 510 Safety Violation
Brood War
General
Which units you wish saw more use in the game? ACS replaced by "ASL Season Open" - Starts 21/02 StarCraft player reflex TE scores [ASL21] Potential Map Candidates Gypsy to Korea
Tourneys
[Megathread] Daily Proleagues Escore Tournament StarCraft Season 1 Small VOD Thread 2.0 KCM Race Survival 2026 Season 1
Strategy
Fighting Spirit mining rates Zealot bombing is no longer popular? Simple Questions, Simple Answers Current Meta
Other Games
General Games
Path of Exile Nintendo Switch Thread Diablo 2 thread Battle Aces/David Kim RTS Megathread ZeroSpace 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
TL Mafia Community Thread Mafia Game Mode Feedback/Ideas Vanilla Mini Mafia
Community
General
US Politics Mega-thread Ask and answer stupid questions here! European Politico-economics QA Mega-thread The Games Industry And ATVI Russo-Ukrainian War Thread
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
World Cup 2022
Tech Support
TL Community
The Automated Ban List
Blogs
ADHD And Gaming Addiction…
TrAiDoS
My 2025 Magic: The Gathering…
DARKING
Life Update and thoughts.
FuDDx
How do archons sleep?
8882
StarCraft improvement
iopq
Customize Sidebar...

Website Feedback

Closed Threads



Active: 2184 users

The Big Programming Thread - Page 852

Forum Index > General Forum
Post a Reply
Prev 1 850 851 852 853 854 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.
spinesheath
Profile Blog Joined June 2009
Germany8679 Posts
February 24 2017 22:28 GMT
#17021
On February 25 2017 05:53 Blisse wrote:
Also in other news, words cannot describe how much I'm disgusted by indie developers.

Been meaning to do foobar2000 development for a while, but never got into it because of the high barrier to entry, so I finally sat down yesterday to plow through getting a build to... build. So many Visual Studio issues to work through, like hardcoded library paths, hardcoded build scripts, missing libs... and the code quality is also so poor. Like seriously, single 3000-line file. the nice part is refactoring stuff will help me learn what's what.

Be fair, you're disgusted by bad developers, not indie developers.
If you have a good reason to disagree with the above, please tell me. Thank you.
Blisse
Profile Blog Joined July 2010
Canada3710 Posts
February 24 2017 22:30 GMT
#17022
On February 25 2017 07:28 spinesheath wrote:
Show nested quote +
On February 25 2017 05:53 Blisse wrote:
Also in other news, words cannot describe how much I'm disgusted by indie developers.

Been meaning to do foobar2000 development for a while, but never got into it because of the high barrier to entry, so I finally sat down yesterday to plow through getting a build to... build. So many Visual Studio issues to work through, like hardcoded library paths, hardcoded build scripts, missing libs... and the code quality is also so poor. Like seriously, single 3000-line file. the nice part is refactoring stuff will help me learn what's what.

Be fair, you're disgusted by bad developers, not indie developers.


There's no difference! *mouth froths uncontrollably*
There is no one like you in the universe.
shz
Profile Blog Joined October 2010
Germany2687 Posts
February 24 2017 23:10 GMT
#17023
On February 25 2017 05:53 Blisse wrote:
Also in other news, words cannot describe how much I'm disgusted by indie developers.

Been meaning to do foobar2000 development for a while, but never got into it because of the high barrier to entry, so I finally sat down yesterday to plow through getting a build to... build. So many Visual Studio issues to work through, like hardcoded library paths, hardcoded build scripts, missing libs... and the code quality is also so poor. Like seriously, single 3000-line file. the nice part is refactoring stuff will help me learn what's what.



Don't you dare criticize our dear lord and savior Peter P.
Liquipedia
phar
Profile Joined August 2011
United States1080 Posts
Last Edited: 2017-02-25 01:49:11
February 25 2017 01:43 GMT
#17024
On February 25 2017 06:15 travis wrote:


also how do C developers not go crazy staring at this shit

Because they are crazy. See https://www.usenix.org/system/files/1311_05-08_mickens.pdf

I would copy some select quotes for enticement but there are so many I can't choose.
Who after all is today speaking about the destruction of the Armenians?
Deleted User 3420
Profile Blog Joined May 2003
24492 Posts
Last Edited: 2017-02-25 03:27:45
February 25 2017 02:31 GMT
#17025
+ Show Spoiler +

http://imgur.com/a/QQaZd

What am I missing about this question? (we include 0 as natural numbers)

Do i need sleep or something?

a and b are natural numbers.
make a = 0 and b = 0

4 * 0 + 5 * 0 = 0
0 >= 0


(i guess they want a and b to not be equal? but is that some rule that I don't know about? they didn't explicitly say that)


oops. click the spoiler if you want to see stupidity. I definitely do need sleep. I see my mistake now. I was thinking "there exists n >= n_0 instead of "for all n >= n_0"
tofucake
Profile Blog Joined October 2009
Hyrule19192 Posts
February 25 2017 02:47 GMT
#17026
0 is not a natural number
Liquipediaasante sana squash banana
Deleted User 3420
Profile Blog Joined May 2003
24492 Posts
Last Edited: 2017-02-25 03:00:21
February 25 2017 02:51 GMT
#17027
it is in our class.

(in other news, I got an interview with amazon)
scudst0rm
Profile Joined May 2010
Canada1149 Posts
February 25 2017 03:30 GMT
#17028
It has to hold for all n > n_0
It works for 0 but not for 1,2,3,6,7,11
You're like a one ranger army comin' at me...
tofucake
Profile Blog Joined October 2009
Hyrule19192 Posts
February 25 2017 03:35 GMT
#17029
On February 25 2017 11:51 travis wrote:
it is in our class.

(in other news, I got an interview with amazon)

well then your class is wrong

good luck with the interview
Liquipediaasante sana squash banana
Deleted User 3420
Profile Blog Joined May 2003
24492 Posts
February 25 2017 03:49 GMT
#17030
On February 25 2017 12:35 tofucake wrote:
Show nested quote +
On February 25 2017 11:51 travis wrote:
it is in our class.

(in other news, I got an interview with amazon)

well then your class is wrong

good luck with the interview


why is the class "wrong". A google search show's that it's pretty obvious there is no consensus.
Mr. Wiggles
Profile Blog Joined August 2010
Canada5894 Posts
February 25 2017 04:46 GMT
#17031
It seems like we have a quorum. As a C developer I'm officially crazy!

In other news I'm going to start working on a device driver at work, which should be fun. I'm wondering if the fact that I'm looking forward to it is a symptom of my insanity.
you gotta dance
bangsholt
Profile Joined June 2011
Denmark138 Posts
Last Edited: 2017-02-25 12:13:08
February 25 2017 12:12 GMT
#17032
Working with device drivers truely is a special kind of insanity.

Good luck, may the data sheet be with you... (Although the real funny part doesn't start until you realize the data sheet is lying, or you have a different HW rev from the one described where there's a change for no apparent reason)
tofucake
Profile Blog Joined October 2009
Hyrule19192 Posts
February 25 2017 13:25 GMT
#17033
On February 25 2017 12:49 travis wrote:
Show nested quote +
On February 25 2017 12:35 tofucake wrote:
On February 25 2017 11:51 travis wrote:
it is in our class.

(in other news, I got an interview with amazon)

well then your class is wrong

good luck with the interview


why is the class "wrong". A google search show's that it's pretty obvious there is no consensus.

well then your homework thinger is wrong
Liquipediaasante sana squash banana
Deleted User 3420
Profile Blog Joined May 2003
24492 Posts
Last Edited: 2017-02-25 15:48:11
February 25 2017 15:06 GMT
#17034
there is something in this project I am having so much trouble putting together
we are supposed to find every instance of a substring in our array of strings, and replace the substring with a new string (of varying length)

but we can't use dynamic memory allocation

it's... a bit beyond me. They didn't really explain how to do this.

So, I have an idea to start.. use strstr in a loop to find pointers to the locations where the targets are found

then I guess I need to copy the string into a new string up to that point
then copy the replacement from that point
then copy the rest of the original string after THAT point

and then replace the original string with my new one

but.. I don't really know how to do this

edit: I think I've figured it out using strcat and strcpy

edit: uh oh. stack smashing detected. that's new for me. think maybe I am copying too much into my string!
DickMcFanny
Profile Blog Joined September 2015
Ireland1076 Posts
February 25 2017 19:30 GMT
#17035
Sorry if that's a stupid question, but how do I express iteration in JS?

Let's say I have a quadratic formula, f(x) = x^2 + 1. f(0) = 1, so the next step is to find out f(1), which is 2, so the next step is to find f(2), which is 5, so the next step is to find f(5), which is 26, so the next step is to find f(26) and so on.

I'm not sure what I should even google, neither in German nor English.
| (• ◡•)|╯ ╰(❍ᴥ❍ʋ)
Acrofales
Profile Joined August 2010
Spain18215 Posts
February 25 2017 19:35 GMT
#17036
could do it recursively, or in a loop, depending on what you need. In a loop, it's pretty trivial:


x = 0;
while(<condition>) {
x = x^2 + 1; //not quite sure on squared syntax in JS, it might be x**2. If in doubt, just write x*x
}
DickMcFanny
Profile Blog Joined September 2015
Ireland1076 Posts
February 25 2017 19:41 GMT
#17037
How would it look recursively?
| (• ◡•)|╯ ╰(❍ᴥ❍ʋ)
Deleted User 3420
Profile Blog Joined May 2003
24492 Posts
February 25 2017 19:41 GMT
#17038
that's easy to do but what are you wanting to do with it? just print the outputs?

like, print out

1
2
5
26

etc?
Deleted User 3420
Profile Blog Joined May 2003
24492 Posts
Last Edited: 2017-02-25 19:45:04
February 25 2017 19:44 GMT
#17039
recursive would be just as simple
x = 0;
function(int x) {
x = x^2 + 1
function(x)
}

of course you'd need to stop it at some point

note: this may not be the syntax for javascript because I don't know javascript
DickMcFanny
Profile Blog Joined September 2015
Ireland1076 Posts
Last Edited: 2017-02-25 20:08:45
February 25 2017 19:48 GMT
#17040
Jesus, that's much easier than I expected.

"like, print out

1
2
5
26"

Exactly. Each change to X should be printed out.
| (• ◡•)|╯ ╰(❍ᴥ❍ʋ)
Prev 1 850 851 852 853 854 1032 Next
Please log in or register to reply.
Live Events Refresh
Replay Cast
00:00
HomeStory Cup 28 - Group C
LiquipediaDiscussion
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
RuFF_SC2 241
NeuroSwarm 202
StarCraft: Brood War
JulyZerg 45
910 37
Icarus 3
Dota 2
monkeys_forever589
LuMiX2
League of Legends
JimRising 800
Super Smash Bros
C9.Mang01263
Mew2King65
Other Games
summit1g15387
tarik_tv5678
ToD115
Moletrap11
Organizations
Other Games
gamesdonequick1227
StarCraft 2
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 12 non-featured ]
StarCraft 2
• davetesta55
• AfreecaTV YouTube
• intothetv
• Kozan
• IndyKCrew
• LaughNgamezSOOP
• Migwel
• sooper7s
StarCraft: Brood War
• BSLYoutube
• STPLYoutube
• ZZZeroYoutube
League of Legends
• Stunt357
Upcoming Events
Sparkling Tuna Cup
6h 24m
LiuLi Cup
7h 24m
Maru vs Reynor
Serral vs Rogue
Ladder Legends
14h 24m
Replay Cast
20h 24m
Replay Cast
1d 5h
Wardi Open
1d 8h
Monday Night Weeklies
1d 13h
OSC
1d 20h
WardiTV Winter Champion…
2 days
Replay Cast
3 days
[ Show More ]
WardiTV Winter Champion…
3 days
Replay Cast
3 days
PiG Sty Festival
4 days
The PondCast
4 days
KCM Race Survival
4 days
WardiTV Winter Champion…
4 days
Replay Cast
4 days
PiG Sty Festival
5 days
Epic.LAN
5 days
Replay Cast
5 days
PiG Sty Festival
6 days
CranKy Ducklings
6 days
Epic.LAN
6 days
Replay Cast
6 days
Liquipedia Results

Completed

Proleague 2026-02-14
Rongyi Cup S3
Underdog Cup #3

Ongoing

KCM Race Survival 2026 Season 1
LiuLi Cup: 2025 Grand Finals
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

Escore Tournament S1: King of Kings
[S:21] ASL SEASON OPEN 1st Round
[S:21] ASL SEASON OPEN 1st Round Qualifier
[S:21] ASL SEASON OPEN 2nd Round
[S:21] ASL SEASON OPEN 2nd Round Qualifier
Acropolis #4
IPSL Spring 2026
HSC XXIX
uThermal 2v2 2026 Main Event
Bellum Gens Elite Stara Zagora 2026
RSL Revival: Season 4
WardiTV Winter 2026
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.