• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EDT 09:38
CEST 15:38
KST 22:38
  • 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
[ASL21] Ro4 Preview: On Course10Code S Season 1 - RO8 Preview7[ASL21] Ro8 Preview Pt2: Progenitors8Code S Season 1 - RO12 Group A: Rogue, Percival, Solar, Zoun13[ASL21] Ro8 Preview Pt1: Inheritors16
Community News
Maestros of The Game 2 announcement and schedule !8Weekly Cups (April 27-May 4): Clem takes triple0RSL Revival: Season 5 - Qualifiers and Main Event12Code S Season 1 (2026) - RO12 Results12026 GSL Season 1 Qualifiers25
StarCraft 2
General
Code S Season 1 - RO8 Preview Behind the Blue - Team Liquid History Book Weekly Cups (April 27-May 4): Clem takes triple Blizzard Classic Cup @ BlizzCon 2026 - $100k prize pool Code S Season 1 (2026) - RO12 Results
Tourneys
Master Swan Open (Global Bronze-Master 2) 2026 GSL Season 2 Qualifiers Maestros of The Game 2 announcement and schedule ! GSL Code S Season 1 (2026) WardiTV Mondays
Strategy
Custom Maps
[D]RTS in all its shapes and glory <3 [A] Nemrods 1/4 players
External Content
Mutation # 525 Wheel of Misfortune The PondCast: SC2 News & Results Mutation # 524 Death and Taxes Mutation # 523 Firewall
Brood War
General
ASL Tickets to Live Event Finals? [ASL21] Ro4 Preview: On Course Quality of life changes in BW that you will like ? Why there arent any 256x256 pro maps? RepMastered™: replay sharing and analyzer site
Tourneys
[ASL21] Semifinals A [BSL22] RO16 Group Stage - 02 - 10 May [Megathread] Daily Proleagues [ASL21] Ro8 Day 3
Strategy
Simple Questions, Simple Answers Fighting Spirit mining rates Muta micro map competition What's the deal with APM & what's its true value
Other Games
General Games
Warcraft III: The Frozen Throne Stormgate/Frost Giant Megathread Path of Exile Nintendo Switch Thread Daigo vs Menard Best of 10
Dota 2
The Story of Wings Gaming
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 Mafia Game Mode Feedback/Ideas TL Mafia Community Thread Five o'clock TL Mafia
Community
General
US Politics Mega-thread European Politico-economics QA Mega-thread Russo-Ukrainian War Thread UK Politics Mega-thread The Letting Off Steam Thread
Fan Clubs
The IdrA Fan Club
Media & Entertainment
Anime Discussion Thread [Manga] One Piece [Req][Books] Good Fantasy/SciFi books
Sports
2024 - 2026 Football Thread McBoner: A hockey love story Formula 1 Discussion
World Cup 2022
Tech Support
streaming software Strange computer issues (software) [G] How to Block Livestream Ads
TL Community
The Automated Ban List
Blogs
How EEG Data Can Predict Gam…
TrAiDoS
ramps on octagon
StaticNine
Funny Nicknames
LUCKY_NOOB
Customize Sidebar...

Website Feedback

Closed Threads



Active: 1276 users

The Big Programming Thread - Page 513

Forum Index > General Forum
Post a Reply
Prev 1 511 512 513 514 515 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.
Grobyc
Profile Blog Joined June 2008
Canada18410 Posts
August 27 2014 07:29 GMT
#10241
One quick question for the Python guys out there: One of the Python guides I'm looking at in the OP is based on Python 3.2.1. I'm assuming that's just because that was the most recent version when the guide was put out, but am I safe to use 3.4.1 for the guide or should I expect some notable differences?
If you watch Godzilla backwards it's about a benevolent lizard who helps rebuild a city and then moonwalks into the ocean.
Morga
Profile Joined August 2010
Belgium35 Posts
August 27 2014 08:04 GMT
#10242
Nah you should be good.
meatpudding
Profile Joined March 2011
Australia520 Posts
August 27 2014 08:06 GMT
#10243
On August 27 2014 16:29 Grobyc wrote:
One quick question for the Python guys out there: One of the Python guides I'm looking at in the OP is based on Python 3.2.1. I'm assuming that's just because that was the most recent version when the guide was put out, but am I safe to use 3.4.1 for the guide or should I expect some notable differences?


I would guess it's ok. I don't know for sure but if you're looking at python.org then you can find an up-to-date one. Also keep in mind that the latest Python 2.x.x branch still sees a lot of use (possibly more than the 3.x.x branch) . Just something to keep in mind that both version 2 and 3 are perfectly fine to use.
Be excellent to each other.
Nesserev
Profile Blog Joined January 2011
Belgium2760 Posts
August 27 2014 08:18 GMT
#10244
--- Nuked ---
Grobyc
Profile Blog Joined June 2008
Canada18410 Posts
Last Edited: 2014-08-27 08:24:46
August 27 2014 08:24 GMT
#10245
Thanks for the quick responses guys
If you watch Godzilla backwards it's about a benevolent lizard who helps rebuild a city and then moonwalks into the ocean.
delHospital
Profile Blog Joined December 2010
Poland261 Posts
Last Edited: 2014-08-27 12:49:43
August 27 2014 12:47 GMT
#10246
On August 27 2014 07:16 Nesserev wrote:
Well, there are many choices, but you probably would want:
- a general scripting language
- a web front-end language
- a language to write programs

Python can do all 3, but it shines the most as a general scripting language. Alternatively, Perl is also used a lot.
PHP/Python as web front-end languages are probably all you will need (and javascript and the whole mess).
If you want to write programs... almost any general programming language will suffice

My recommendation: Python, C++ and Bash(Unix shell scripting) will get you very far.

Web front-end is HTML, CSS, and JS. PHP, Python, and Perl are back-end languages.

@Grobyc, if you want to create websites, you need to know HTML, CSS, JS, a back-end language (PHP, Python, Perl, Ruby, JS, C#, almost any language), and SQL. You will also have to learn how to use libraries like jQuery and Django/RoR/ASP.NET/whatever-applies-in-your-case, how to configure web servers (Apache, nginx), SQL severs (PostgreSQL, MySQL/MariaDB, MSSQL). And you need to know how HTTP works.

If you want to create network clients and servers, you most likely need C and C++. Possibly a higher level language like Java. Possibly even Erlang. You also need to know how to use the tools provided by your operating system and programming language library/runtime system (processes, threads, other kinds of IO concurrency, IPC, sockets, etc.). And obviously, you will need knowledge of network protocols.

Unless you only develop on Windows and for Windows, you should also know shell scripting (not only syntax, but also commonly used utilities and all kinds of traps you can fall into).

Oh, and use git. It's pretty useful
Nesserev
Profile Blog Joined January 2011
Belgium2760 Posts
August 27 2014 13:09 GMT
#10247
--- Nuked ---
tofucake
Profile Blog Joined October 2009
Hyrule19210 Posts
August 27 2014 14:33 GMT
#10248
For backend, stick with PHP. It's ubiquitous and easy (though that makes it easy to write really bad code). Most hosts won't let you run Node on shared servers, so it's best to learn JS for front end stuff and then fiddle with Node on your own.
Liquipediaasante sana squash banana
obesechicken13
Profile Blog Joined July 2008
United States10467 Posts
Last Edited: 2014-08-27 15:13:33
August 27 2014 15:12 GMT
#10249
Is python 2.7 still more popular than 3? People say there's a lot of backwards compatibility. Last year I wanted to do simple guis for an app and I can't find any good libraries and there are bugs everywhere and windows binaries are all 2.7 and documentation is still all 2.7 :/
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.
CatNzHat
Profile Blog Joined February 2011
United States1599 Posts
August 27 2014 16:29 GMT
#10250
From a web perspective Python 3 is definitely used more: http://trends.builtwith.com/framework/Python

I'd put Ruby high on the list for web back-end languages. Sinatra and Rails make it easy to get something up and running without too much effort, which is important to keep from losing interest.
delHospital
Profile Blog Joined December 2010
Poland261 Posts
Last Edited: 2014-08-27 17:46:54
August 27 2014 17:43 GMT
#10251
On August 28 2014 01:29 CatNzHat wrote:
From a web perspective Python 3 is definitely used more: http://trends.builtwith.com/framework/Python

I'd put Ruby high on the list for web back-end languages. Sinatra and Rails make it easy to get something up and running without too much effort, which is important to keep from losing interest.

from the website you linked: python 2.6: 400k, how is python 3 used more??

e: oh, the question was specifically about 2.7. sorry, didn't see
Manit0u
Profile Blog Joined August 2004
Poland17743 Posts
Last Edited: 2014-08-29 08:33:42
August 29 2014 08:33 GMT
#10252
Have any of you used the PHP Excel library before?

I have this little thingie in my code...


if ($testType == 'before') {
$objPHPExcel->getSheetByName($spreadsheetTitle)->mergeCells('J1:N1')
->mergeCells('O1:R1')
->mergeCells('U1:X1')
->mergeCells('Y1:AB1')
->mergeCells('AC1:AF1');
} else {
$objPHPExcel->getSheetByName($spreadsheetTitle)->mergeCells('J1:M1')
->mergeCells('P1:S1')
->mergeCells('T1:W1')
->mergeCells('X1:AA1')
->mergeCells('AH1:AL1');
}


It works correctly for the 'before' part but the else part doesn't for some reason (cells disappear).

Expectations:
|-----|-----| <-- merged cells (preserving all cells, just expanding them)
|--|--|--|--|

Reality:
|-----------| <-- some cells disappear
|--|--|--|--|

Documentation:
https://github.com/PHPOffice/PHPExcel/wiki/User Documentation
Time is precious. Waste it wisely.
nunez
Profile Blog Joined February 2011
Norway4003 Posts
Last Edited: 2014-08-29 11:35:55
August 29 2014 11:30 GMT
#10253
ah, just finished a pet project i have been working / thinking on for months (?) after having fever dreams about it last night where it seemed hopeless.
an nnary-apply_visitor for my variant (now called mux_t) that i posted earlier.

apply_visitor(visitor,visitable0,...,visitableN-1);
( demux(demuxer,mux0,...,muxN-1) )

took a some shortcuts and will have to tinker with it, some of the machinery behind it looks absolutely horryfying. finally solving the problem feels good, and going from a trivial unary apply_visitor to an nnary apply_visitor is pretty effin' sweet if i may say so myself. allthough i think compilation time when N grows large will be insane.

can now write:
struct print_t{
typedef void return_type;
template<class t_i>
void operator()(t_i&& v_i){
std::cout<<typeid(t_i).name()<<": "<<v_i<<std::endl;
}
template<class t_i,class... t_j>
void operator()(t_i&& v_i,t_j&&... v_j){
(*this)(std::forward<t_i>(v_i)),(*this)(std::forward<t_j>(v_j)...);
}
};

typedef mux_t<int,char,float,std::string> mux;

int main(){
mux a(int(2));
mux b(char('a'));
mux c(float(3.14));
mux d(std::string("teamliquid"));

demux(print_t(),a,b,c,d);
std::cout<<std::endl;
demux(print_t(),d,b,d,c,a);
}

[jeh@gloin workbench]$ make
g++ -std=c++14 -O3 -I. -I../ -fdiagnostics-color=auto -c main.cpp -o main.o
g++ -std=c++14 -O3 -I. -I../ -fdiagnostics-color=auto main.o -o workbench
rm -rf *o
[jeh@gloin workbench]$ ./workbench
i: 2
c: a
f: 3.14
Ss: teamliquid

Ss: teamliquid
c: a
Ss: teamliquid
f: 3.14
i: 2
[jeh@gloin workbench]$
conspired against by a confederacy of dunces.
delHospital
Profile Blog Joined December 2010
Poland261 Posts
August 29 2014 21:12 GMT
#10254
On August 29 2014 20:30 nunez wrote:
[jeh@gloin workbench]$ make
g++ -std=c++14 -O3 -I. -I../ -fdiagnostics-color=auto -c main.cpp -o main.o
g++ -std=c++14 -O3 -I. -I../ -fdiagnostics-color=auto main.o -o workbench
rm -rf *o

Forcefully removing all files and directories ending with an "o" when you run make... ballsy.
bardtown
Profile Joined June 2011
England2313 Posts
August 29 2014 22:38 GMT
#10255
I have started with Python this week, after a long break from programming (in the past I used C++, and I miss everything about it but I needed to be able to produce functional programs more quickly, and most modelling seems to use scripting languages). Now familiar with most of the basics of the language.

I would like to create a graph of hexagons, in which each hexagon will change its state based on the surrounding hexagons. Is there some sort of visual library which will allow me to do this simply, or would it be more straightforward for me to use a coordinate system and perhaps add the hexagons later as a visual aid? Hope that makes sense.
meatpudding
Profile Joined March 2011
Australia520 Posts
August 30 2014 00:02 GMT
#10256
On August 30 2014 07:38 bardtown wrote:
I have started with Python this week, after a long break from programming (in the past I used C++, and I miss everything about it but I needed to be able to produce functional programs more quickly, and most modelling seems to use scripting languages). Now familiar with most of the basics of the language.

I would like to create a graph of hexagons, in which each hexagon will change its state based on the surrounding hexagons. Is there some sort of visual library which will allow me to do this simply, or would it be more straightforward for me to use a coordinate system and perhaps add the hexagons later as a visual aid? Hope that makes sense.


Pygame is an easy but basic graphics library. I've used it. It's ok but I don't strongly recommend it.

Maybe take a look at SciPy and Numeric libraries for a visual plot library, I don't know of any off the top of my head.

If you don't mind outputting to data (text) files and running another process to produce images, then use gnuplot. It can take a while to learn but I've been using it for almost everything since I picked it up.
Be excellent to each other.
Blisse
Profile Blog Joined July 2010
Canada3710 Posts
Last Edited: 2014-08-30 02:23:52
August 30 2014 02:23 GMT
#10257
If I wanted to hold a direct connection to a computer/device from another computer/device, how would I do that? I mean like, not routing the connection to a server then back down. Directly. Is that even possible? What would be the closest?
There is no one like you in the universe.
Cyx.
Profile Joined November 2010
Canada806 Posts
August 30 2014 02:28 GMT
#10258
On August 29 2014 20:30 nunez wrote:<snip>

yo nunez I'm about to go away for like a week but I swear to god when I get back I'm going to sit down and actually understand some of the shit you post... it always looks cool but I never have time to actually sit down and look at what it is
Prillan
Profile Joined August 2011
Sweden350 Posts
August 30 2014 07:55 GMT
#10259
On August 30 2014 11:23 Blisse wrote:
If I wanted to hold a direct connection to a computer/device from another computer/device, how would I do that? I mean like, not routing the connection to a server then back down. Directly. Is that even possible? What would be the closest?

Of course, take a look at sockets. It can look very different depending on your language.
TheBB's sidekick, aligulac.com | "Reality is frequently inaccurate." - Douglas Adams
Blisse
Profile Blog Joined July 2010
Canada3710 Posts
Last Edited: 2014-08-30 09:23:06
August 30 2014 09:22 GMT
#10260
On August 30 2014 16:55 Prillan wrote:
Show nested quote +
On August 30 2014 11:23 Blisse wrote:
If I wanted to hold a direct connection to a computer/device from another computer/device, how would I do that? I mean like, not routing the connection to a server then back down. Directly. Is that even possible? What would be the closest?

Of course, take a look at sockets. It can look very different depending on your language.


I know what sockets are. Am I just asking if I can host my own server at home? I think I'm basically asking that.
There is no one like you in the universe.
Prev 1 511 512 513 514 515 1032 Next
Please log in or register to reply.
Live Events Refresh
Wardi Open
12:00
#86
WardiTV732
Rex105
Liquipedia
GSL
08:00
2026 Season 2: Qualifiers
SHIN vs CreatorLIVE!
Zoun vs Cure
IntoTheiNu 1122
CranKy Ducklings SOOP111
LiquipediaDiscussion
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
OGKoka 301
Rex 105
MaxPax 95
ProTech56
StarCraft: Brood War
Calm 8822
Bisu 2698
Sea 1895
Jaedong 1483
Leta 1252
Horang2 976
EffOrt 620
Hyuk 486
BeSt 375
Mini 312
[ Show more ]
actioN 299
ggaemo 234
ZerO 226
firebathero 193
Soulkey 189
Larva 183
Snow 173
Rush 167
Mind 113
Hyun 91
Pusan 85
Sharp 75
Sea.KH 63
HiyA 55
Aegong 45
Mong 43
Killer 35
Barracks 29
soO 28
sorry 26
[sc1f]eonzerg 22
SilentControl 16
Hm[arnc] 15
IntoTheRainbow 15
Bale 13
Movie 8
Terrorterran 7
Icarus 7
Dota 2
Gorgc2373
XcaliburYe274
syndereN34
NeuroSwarm10
Counter-Strike
byalli357
Other Games
B2W.Neo918
hiko820
Lowko387
crisheroes193
monkeys_forever131
ArmadaUGS113
elazer93
Livibee45
Happy40
ZerO(Twitch)8
Hui .0
Organizations
Counter-Strike
PGL35555
StarCraft 2
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
[ Show 14 non-featured ]
StarCraft 2
• AfreecaTV YouTube
• intothetv
• Kozan
• IndyKCrew
• LaughNgamezSOOP
• Migwel
• sooper7s
StarCraft: Brood War
• HerbMon 45
• BSLYoutube
• STPLYoutube
• ZZZeroYoutube
League of Legends
• Nemesis4422
• TFBlade1235
Other Games
• WagamamaTV437
Upcoming Events
Monday Night Weeklies
2h 22m
OSC
10h 22m
CranKy Ducklings
20h 22m
Afreeca Starleague
20h 22m
Light vs Flash
PiGosaur Cup
1d 10h
Replay Cast
1d 19h
Replay Cast
2 days
The PondCast
2 days
OSC
2 days
Replay Cast
3 days
[ Show More ]
RSL Revival
3 days
OSC
3 days
Korean StarCraft League
4 days
RSL Revival
4 days
BSL
5 days
GSL
5 days
Cure vs TBD
TBD vs Maru
BSL
6 days
Replay Cast
6 days
Liquipedia Results

Completed

CSL 2026 SPRING (S20)
WardiTV TLMC #16
Nations Cup 2026

Ongoing

BSL Season 22
ASL Season 21
IPSL Spring 2026
KCM Race Survival 2026 Season 2
Acropolis #4
KK 2v2 League Season 1
BSL 22 Non-Korean Championship
SCTL 2026 Spring
RSL Revival: Season 5
2026 GSL S1
Asian Champions League 2026
IEM Atlanta 2026
PGL Astana 2026
BLAST Rivals Spring 2026
IEM Rio 2026
PGL Bucharest 2026
Stake Ranked Episode 1
BLAST Open Spring 2026
ESL Pro League S23 Finals
ESL Pro League S23 Stage 1&2

Upcoming

Escore Tournament S2: W7
YSL S3
Escore Tournament S2: W8
CSLAN 4
Kung Fu Cup 2026 Grand Finals
HSC XXIX
uThermal 2v2 2026 Main Event
Maestros of the Game 2
2026 GSL S2
BLAST Bounty Summer 2026: Closed Qualifier
Stake Ranked Episode 3
XSE Pro League 2026
IEM Cologne Major 2026
Stake Ranked Episode 2
CS Asia Championships 2026
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.