5 ms·
Play blackjack in Excel
- bilbobaggie 14y agoI thought the point of IronSpread was to increase productivity.
- thanosbaskous 14y agoExcel can do some pretty impressive things. Another cool-but-probably-useless example: Excel as a 3d engine http://www.gamasutra.com/view/feature/131968/microsoft_excel_revolutionary_3d_.php?print=1 http://www.gamasutra.com/view/feature/131968/microsoft_excel... Check out the videos to get a quick understanding of what they did.
- Metrop0218 14y agoThat's nuts
- dmboyd 14y agoEssentially, excel is a functional language, without the ability for recursion. If there were a built in array datatype, that'd be possible. There's a few papers floating around explaining an integration between Haskell and excel, described in some places as hsExcel, but I haven't seen a working copy.
- coroxout 14y agoHa, that's great. I knocked up a more or less working FreeCell solitaire in Excel one bored afternoon, so Blackjack should certainly be possible in plain old Excel VBA. Most impressive Excel things I've seen by other people: a Game of Life (I'm guessing not SeanDav's, but who knows!), a Dijkstra's algorithm demo which let you resize cells and recalculated the shortest distance between two cells, and this rather impressive Enigma cipher encoder/decoder: http://news.ycombinator.com/item?id=3755656 http://news.ycombinator.com/item?id=3755656
- deleted 14y ago[deleted]
- chris_mahan 14y agospeaking of, it says on their FAQ that they will be able to call python function from excel mid-july. Update? Or maybe we're talking a different year, not 2012?
- karamazov 14y agoThis works! See our docs: http://ironspread.com/docs.html#udf http://ironspread.com/docs.html#udf The FAQ is updated - thanks for pointing it out.
- robomartin 14y agoProbably a cool way to learn and apply Python too.
- K2h 14y agoI like the snarky remarks at the end of the code like: dealer_says("Now I have to go back to working as a VBA programmer!")
- Ives 14y agoThe same thing is possible in Excel VBA by creating a Private Sub Worksheet_Change(ByVal Target As Range) in the appropriate worksheet, which will be called when a cell is changed. I don't see any reason why a complete blackjack game would be impossible. I am however sure that the python code is much nicer than the VBA code to do so, and if it weren't for the distribution trouble (requiring a plugin to be installed for all users of the workbook) I'd definitely use IronSpread.
- devmach 14y agoIf it's python, if i'm able to use python modules and call functions from excel ( udf ), why IronSpread folks pushes for useless demos ? Show me some network stuff. Show me how can i write a simple crm ( no not like the one on their blog ) " with " centeral db and gives me ability to work with my coworkers together. Show me how can i gather information from different sources ( web, db v.s. ) and analyse it.
- miratom 14y agoSo? Play PacMan in excel: http://www.cypherhackz.net/archives/2006/10/05/play-pacman-in-excel/ http://www.cypherhackz.net/archives/2006/10/05/play-pacman-i...
- karamazov 14y agoWe work with Excel 2007 and 2010 ;)
- dmboyd 14y agoOr there's always the lighter weight option pyspread[1] in which cells are objects, works with numpy arrays and any module. [1]: http://manns.github.com/pyspread/ http://manns.github.com/pyspread/
- SeanDav 14y agoFor a bit of a laugh I wrote a Conway's Game of Life in Excel using cells as pixels. I could get quite smooth animation up to a screen size of around 200x200 cells. The main bottleneck was the need to check every cell in the grid, every generation, which quickly becomes hard for VBA to do smoothly. It was fun however to see Excel doing animation.
- josephagoss 14y agoLater year students have taken control of our entire pilot plant for our electrical 'controls and instrumentation' engineering with excel. Very impressive, I used to scoff at the engineers using excel (I'm a Computer Science and Electrical Engineering student) but it can do some excellent stuff.
- perssontm 14y agoI wouldnt be surprised if theese guys are beeing bought by MS sooner rather than later. Replacing VBA feels like it should be quite high on the priority list.