Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Why are modern game engines....

Name: Anonymous 2013-03-14 18:31

programmed in C++ and not C?

If they are going to use OO (false-OO) then they should use D.

Name: Anonymous 2013-03-14 18:36

Symta (cause every file is closure):

Balance: 150
deposit D = !Balance+D
withdraw W = !Balance: max 0 Balance-W



Self:

() balance: 150
   deposit: [d | balance: balance + d]
   withdraw: [w | balance: (0 max: balance - w)]



C/C++:

class Account {
public:
  int balance;
  Account(init startBalance) {
    balance = startBalance;
  }
  void deposit(int d) {
    balance += d;
  }
  void withdraw(int w) {
    balance = max(0, balance-w);
  }
};

Account(150);

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List