| View previous topic :: View next topic |
| Author |
Message |
deleted19776 I post too much
Reputation: 11
Joined: 29 Apr 2007 Posts: 3838
|
Posted: Sun Feb 22, 2015 6:39 am Post subject: Please tell me recursion isn't used in cuuurrpuuurrations |
|
|
| Plz, I've had enough just from this functional programming class.
|
|
| Back to top |
|
 |
Nirojan How do I cheat?
Reputation: 108
Joined: 16 Sep 2008 Posts: 0 Location: seshville
|
Posted: Sun Feb 22, 2015 5:24 pm Post subject: |
|
|
recursion is used in corporations
_________________
| Quote: | | yo i b 22 tryna make it in dis rap game but da steetz dont got luv for no wun na mean so im out hea tryna holla at da fams on dis innernet shit u no way i sayin |
|
|
| Back to top |
|
 |
Zanzer I post too much
Reputation: 126
Joined: 09 Jun 2013 Posts: 3278
|
Posted: Sun Feb 22, 2015 5:58 pm Post subject: |
|
|
Recursive functions make much better loops. It's called job security!
| Code: | function calc(int[] values, int index, int total) {
if (index >= values.length)
return total;
return calc(values, index + 1, total + values[index]);
} |
|
|
| Back to top |
|
 |
deleted19776 I post too much
Reputation: 11
Joined: 29 Apr 2007 Posts: 3838
|
Posted: Sun Feb 22, 2015 8:54 pm Post subject: |
|
|
| Zanzer wrote: | Recursive functions make much better loops. It's called job security!
| Code: | function calc(int[] values, int index, int total) {
if (index >= values.length)
return total;
return calc(values, index + 1, total + values[index]);
} |
|
Fuck it, I know I'm going to systems at this point.
|
|
| Back to top |
|
 |
cokefag Master Cheater
Reputation: 51
Joined: 15 Nov 2007 Posts: 488
|
Posted: Sun Feb 22, 2015 9:13 pm Post subject: |
|
|
| Waxxup wrote: | | Zanzer wrote: | Recursive functions make much better loops. It's called job security!
| Code: | function calc(int[] values, int index, int total) {
if (index >= values.length)
return total;
return calc(values, index + 1, total + values[index]);
} |
|
Fuck it, I know I'm going to systems at this point. |
tfw have enthusiasm to become a computer scientist and immediately want to go into IT after entering university.
|
|
| Back to top |
|
 |
deleted19776 I post too much
Reputation: 11
Joined: 29 Apr 2007 Posts: 3838
|
Posted: Mon Feb 23, 2015 12:55 am Post subject: |
|
|
| cokefag wrote: | | Waxxup wrote: | | Zanzer wrote: | Recursive functions make much better loops. It's called job security!
| Code: | function calc(int[] values, int index, int total) {
if (index >= values.length)
return total;
return calc(values, index + 1, total + values[index]);
} |
|
Fuck it, I know I'm going to systems at this point. |
tfw have enthusiasm to become a computer scientist and immediately want to go into IT after entering university. |
Nah not IT, I want to do something more like C, C++, and perhaps Verilog with FPGAs. I like hardware and low level systems so far.
|
|
| Back to top |
|
 |
cokefag Master Cheater
Reputation: 51
Joined: 15 Nov 2007 Posts: 488
|
Posted: Mon Feb 23, 2015 2:48 am Post subject: |
|
|
| Waxxup wrote: | | cokefag wrote: | | Waxxup wrote: | | Zanzer wrote: | Recursive functions make much better loops. It's called job security!
| Code: | function calc(int[] values, int index, int total) {
if (index >= values.length)
return total;
return calc(values, index + 1, total + values[index]);
} |
|
Fuck it, I know I'm going to systems at this point. |
tfw have enthusiasm to become a computer scientist and immediately want to go into IT after entering university. |
Nah not IT, I want to do something more like C, C++, and perhaps Verilog with FPGAs. I like hardware and low level systems so far. |
im not talking about you faggot
fuck comp sci, its for fucking nerds
|
|
| Back to top |
|
 |
deleted19776 I post too much
Reputation: 11
Joined: 29 Apr 2007 Posts: 3838
|
Posted: Mon Feb 23, 2015 3:05 am Post subject: |
|
|
| Eh fuck recursion. Iteration all the way across the sky and rainbows.
|
|
| Back to top |
|
 |
|