[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y ] [Home]
4chanarchives logo
Why is Lisp so used by hobbyists, but so little by professionals?
Images are sometimes not shown due to bandwidth/network limitations. Refreshing the page usually helps.

You are currently reading a thread in /g/ - Technology

Thread replies: 159
Thread images: 12
File: 8318_large.png (208 KB, 655x366) Image search: [Google]
8318_large.png
208 KB, 655x366
Why is Lisp so used by hobbyists, but so little by professionals?
>>
Time isn't free when you're working.
>>
>>54285441
What do you mean?
>>
>>54285465
Not him, but it means pissing about costs money which is why (in his opinion) professionals don't use it for the most part.

I would probably mostly agree: these days there aren't enough people using lisp to justify using it if you are starting something new.

There are exceptions though, AutoLisp for example.
>>
>>54285505
But many people switch to the new languages (Go, Rust, etc.) when they need it...
>>
>>54285208
I tend to use lisp for math stuff because it lets you program in any style and prefix notation is much easier for my brain to parse/evaluate.
>>
>>54287414
You aren't the special snowflake you think you are.
>>
OYVEY
>>
File: 45236499_p0_master1200.jpg (134 KB, 400x400) Image search: [Google]
45236499_p0_master1200.jpg
134 KB, 400x400
>>
(Lots of ((Irritating, Spurious) (Parentheses)))

/THREAD
>>
UNIX
>>
File: triggered.gif (133 KB, 311x366) Image search: [Google]
triggered.gif
133 KB, 311x366
LISP is an ableist word that oppresses people with speech impediments and should therefore not be used as a word or as a programming language, ever.
>>
>>54285208
Oy vey, is that a Menorah?
>>
File: clisp.png (810 B, 48x48) Image search: [Google]
clisp.png
810 B, 48x48
>>54287908
Yeah it's the CLISP logo
>>
>>54285208
AI winter.
It's not due to its capabilities, the likes of carmack and gavin have demonstrated as much.
>>
>>54287908
Yup, not even a hanukia.
>>
>>54285208
many people using clojure though?
>>
interesting read involving lisp being used at a startup: http://www.paulgraham.com/avg.html
>>
>>54290448
It's not a lisp, it's a skin for java.
>>
>>54290579
>2001-2003
>>
>The CLISP developers, both the original creators and the current maintainers, do not subscribe to the mainstream view that blames the Jews for everything from high oil prices and Islamic extremism to El NiƱo and global warming (or cooling, whatever the looming disaster du jour is).

>Moreover, today, when Jews are being pushed out of the American and European academic institutions with various obscene boycott and divestment campaigns, it is crucial for all of us to stand together against the resurgence of Nazism.

Oh vey
>>
>>54290668
You can't get more jewish than this
>>
>>54290760
You could, if you were RMS.
>>
>>54285552
Go/Rust are easier to switch to for most developers than lisp.
>>
>>54291263
>Go/Rust are easier to switch to for most developers than lisp.

>>54285208
The real reason is that you can and will use LISP as metalanguage to make your own DSL. Some dialects take this to more extremes than others, but at the end of the day nobody with a working brain knows that, as soon as Lisp has more and more usage, you sooner or later will stumble upon somefaggots elses DSL that is as expressive as assembly, thought through as PHP or robust as JS.
>>
>>54293321
>but at the end of the day nobody with a working brain knows
*everybody
>>
>>54287414
https://www.youtube.com/watch?v=YgHNtzxO0y8
>>
>>54293321
>not using Forth to create your own DSL on the bare metal
pleb
>>
>>54287908
The authors of clisp are Iraeli nationalists, no joke. Why they decided a lisp compiler would be the best place to broadcast their political beliefs is beyond me.
>>
>>54285208
isnt python a much better option?
>>
>>54295531
what in the actual fuck

fuck lisp, gonna go with rust or erlang, no jewish shit for me, fuck off back to shittit with your zionism
>>
>>54285208
because it's a pleasure to program in it.
>>
Just imagine the problem it would be to maintain a relatively big project, the syntax of lisp it's not very comment friendly

this
>>54287749
>>
>>54295592
>rust
>literal CoC
>no jewish shit
Hehehehehee good goy
>>
>>54295619
I love this meme, say it again!
>>
>>54287749
>he doesn't understand the joy of the syntax melting away and leaving only the pure semantics.
>>
>>54295773
this. Homoiconicity4lyfe
>>
>>54295619
>first language to have docstrings
>not comment friendly
>can literally introspect and edit code live in the interpreter/debugger
>>
>>54287803
>>>/reddit/
>>
>>54295820
>>54295810
>>54295773
Fucking this. Almost always, when someone doesn't like lisp, it's because they've never used it. The only 3 valid complaints about lisp are its poor native typesystem (i.e. not CLOS) (one day someone will fix this), the lack of implementation with a non-shit GC or without a GC (linear types, ...) and the lack of quality libraries.
>>
>>54296009
>poor native typesystem (i.e. not CLOS) (one day someone will fix this), the lack of implementation with a non-shit GC or without a GC (linear types, ...) and the lack of quality libraries.
Scala doesn't have any of these problems.
Why not use Scala?
>>
>>54296051
I was about to look for and link the scala collections video but then I decided not to bother.
Also the fact that it's a jvm language and there is no jvm that is secure by any stretch. Beside, memory usage is through the roof.
>>
>>54295531
You could just use a different interpreter.
>>
>>54296127
Speaking of which, CL is probably the highest level language that has a formal specification.
>>
>>54296127
It doesn't bother me that much. I was a little annoyed initially because they are trying to introduce a controversial political topic into something that should transcend politics. I'll probably look into alternatives when I have time.
>>
>>54296101
Plus, it has none of the pros of lisp.
>>
File: Serial Experiments Lain.gif (1016 KB, 500x357) Image search: [Google]
Serial Experiments Lain.gif
1016 KB, 500x357
The only thing I know about Lisp is pic related.
What is Lisp used for? Are there specific applications that people like to use Lisp for?
>>
>>54296220
Not anymore there aren't. Nasa used it for their mars rover, carmack uses it for VR scripting, naughty dogs used it for all their games, and it was very popular in AI back when AI was about symbol processing.
>>
>>54296220
GNU Emacs is written in a dialect of lisp with the exception of the core.
There are some interesting extensions written for it.
That's probably the most popular use for lisp.
>>
>>54295055
>wanting to use a partial run-time macro assembler that kills lot of optimization opportunities as the compiler doesn't know about bigger parts of the programs
>>
>>54291263
>implying Lisp syntax isn't ridiculously simple
>>
Because professionals (user-facing software and web dev) work in large teams with high turnover rates, so something standardized, blubbish, and a little (forced) OOP is pretty much a must so newbies and idiots can't ruin everything. A relatively small team of tight knit pros is the exception, not the rule. Using a popular language is also a must, because you have to be able to quickly replace employees.

With hobby programming, you have a small team of tight knit programmers or just one programmer, so a powerful multiparadigm language werks fine

>>54296393
Most developers are surprisingly unintelligent and can not learn to be productive with a radically different langauge
>>
>>54296009
>The only 3 valid complaints about lisp are its poor native typesystem (i.e. not CLOS) (one day someone will fix this), the lack of implementation with a non-shit GC or without a GC (linear types, ...) and the lack of quality libraries.
Clojure solves the latter two.
>>
>>54296565
>java GCs
>non-shit
>java
>quality libraries
Pajeet...
>>
which functional language is fun for beginners? if lisp, which dialect?
>>
>>54290668

Now I want to make Nazilisp.

>>54295592
Faggot, use picolisp.
Its german and a great middle ground between the simplicity of scheme and the usefulness of CL.
>>
>>54297058
I'm guessing anyone that has turtle function is what your looking for.
>>
>>54297114
>picolisp
>useful in any way
Plus it looks like crap, it has none of the elegance of scheme.
>>
>>54297114
>implying he shouldn't just use Scheme or Common Lisp
>>
File: SICP.jpg (51 KB, 400x579) Image search: [Google]
SICP.jpg
51 KB, 400x579
>>>54297058 https://mitpress.mit.edu/sicp/full-text/book/book.html
Structure and Interpretation of Computer Programmers is /the/ starting book for new programmers, and it uses Scheme.
>>
>>54296307
>compiler doesn't know
You obviously have no idea what you're talking about.
>>
>>54297665
Found the inbred!
>>
>>54296794
JVM has superb GC.
You can also use CLR or JS, if you prefer.
>>
>>54297716
Lol'd
>>
File: 1421878084725.png (284 KB, 491x491) Image search: [Google]
1421878084725.png
284 KB, 491x491
>>54287947
>>
>>54297114
>Now I want to make Nazilisp.
should be called apocalisp
>>
>>54295773
>syntax melting away
Then why even have the parentheses?

Face it, Lisp is a retarded language designed by a retard for use by retards.
>>
>>54297805
bait.tiff
>>
>>54285208
Because Lisp is not a programming language, is building material, and because of this every Lisp (as in CL) programmer writes its own language that you need to learn before being able to contribute in some project.

In other words: Lisp programmers are autistic faggots that can work with other people.
>>
>>54297892
>In other words: Lisp programmers are autistic faggots that can work with other people.
"'t" missing, I guess.

>>54297665
It's still a compiler OR a macroassembler.

Regardless of Forth degenerates that'd like to call it a Forth system.
Regardless of JS plebosaurs that'd like to call it transpiler.
>>
>>54297805
>Then why even have the parentheses?
See, this is exactly what an unenlightened person would say. There are lots of projects that modify Lisp to not use parentheses (like http://www.xn--drachentrnen-ocb.de/light/english/wisp-lisp-indentation-preprocessor)

It doesn't matter whether Lisp uses parentheses or indentation or keywords or braces or colons, as long as you keep the lists, Lisp is Lisp.

It's precisely because it doesn't matter that all Lisp users agree to standardize on parentheses instead of arguing over trivial things like Algol programmers and where to put their fucking curly braces.
>>
>>54297392

Its way more useful than scheme, I use it for my algo trading and its great, can call and inline C and java natively.
If anything the new page took a shit all over, guess Alex is too much of a pussy to say no to free "web design"
>>
>>54297789

>shoahlisp
>auschlizp
>/pol/isp
Anything else come to mind?
>>
>>54296393
Lisp programmers use a different meaning of syntax than anyone else, e.g. to everyone else, the syntax of LOOP is part of the syntax of Lisp.

To a Lisp programmer, only the reader is syntax.
>>
>>54298483
>To a Lisp programmer, only the reader is syntax.
2deep4me
>>
>>54298238
Well, with shit like easyffi from chicken, I really don't see how just calling C inline is any advantage. Aside from that, that doesn't address my points.
>>
>>54291263
Yeah, that's because Go/Rust aren't memes
>>
>>54291263

s/>>54291263/>>54285552
>>
>>54299137
>go
>not the definition of a meme
>any language with a CoC
>not a meme
Nice meme!
>>
>>54298925

Its more elegant and succinct dude.
Compare:
(define (bubble-sort x gt?)
(letrec
((fix (lambda (f i)
(if (equal? i (f i))
i
(fix f (f i)))))

(sort-step (lambda (l)
(if (or (null? l) (null? (cdr l)))
l
(if (gt? (car l) (cadr l))
(cons (cadr l) (sort-step (cons (car l) (cddr l))))
(cons (car l) (sort-step (cdr l))))))))

(fix sort-step x)))


And:
(defun bubble-sort-vector (vector predicate &aux (len (1- (length vector))))
(do ((swapped t)) ((not swapped) vector)
(setf swapped nil)
(do ((i (min 0 len) (1+ i))) ((eql i len))
(when (funcall predicate (aref vector (1+ i)) (aref vector i))
(rotatef (aref vector i) (aref vector (1+ i)))
(setf swapped t)))))

(defun bubble-sort-list (list predicate)
(do ((swapped t)) ((not swapped) list)
(setf swapped nil)
(do ((list list (rest list))) ((endp (rest list)))
(when (funcall predicate (second list) (first list))
(rotatef (first list) (second list))
(setf swapped t)))))

(defun bubble-sort (sequence predicate)
(etypecase sequence
(list (bubble-sort-list sequence predicate))
(vector (bubble-sort-vector sequence predicate))))


With:
(de bubbleSort (Lst)
(use Chg
(loop
(off Chg)
(for (L Lst (cdr L) (cdr L))
(when (> (car L) (cadr L))
(xchg L (cdr L))
(on Chg) ) )
(NIL Chg Lst) ) ) )


Less redundant parentheses, no redundant lambda declarations or letrecs(due to dynamic binding)
>>
>>54299167
>I have literally no clue how to program in lisp or scheme therefore my strawman is totally legit bro!
Picolisp confirmed for absolute undeniable dogshit.
>>
>>54299182

Its the actual rosetta code examples you retard.
>>
>>54299207
>picoshill are inbred
Who would've thunk?
>>
>>54299167
so is picoshill er i mean picolisp the best?
the code example is obviously shorter.
btw, isn't balancing all those parenthesis a pain in the ass?

im thinking about learning lisp. don't know what dialect to pick, was going to go with common
>>
File: readImage?iid=9310200.jpg (21 KB, 494x298) Image search: [Google]
readImage?iid=9310200.jpg
21 KB, 494x298
>>54299167
never programmed in a functional language and what the fuck am I looking at?
>>
>>54301840
you're looking at the "Bubble Sort" algorithm as implemented in different dialects (versions) of Lisp
[spoiler]i don't know lisp
>>
>>54301840
lisp aint functional
>>
>>54301863
so you're saying everything all that code does is just the bubble sort, which takes a few lines of clear code in any imperative language? I thought it just used bubble sort for something. how is lisp not a meme?
>>
File: hitler-approves-of-your-post.jpg (142 KB, 591x411) Image search: [Google]
hitler-approves-of-your-post.jpg
142 KB, 591x411
>>54298254
what about national socialisp
>>
>>54299167
>Less redundant parentheses, no redundant lambda declarations or letrecs(due to dynamic binding)
The algorithm isn't even the same across those snippets.
>>
>>54301882
Yes it is fucknut, just not pure functional like Haskell.
>>
>>54285465
There's this old saying
>Lisp programmers know the value of everything and the cost of nothing
>>
File: ROFL Mao.jpg (85 KB, 381x280) Image search: [Google]
ROFL Mao.jpg
85 KB, 381x280
>>54297114
>>54297789
>>54298254
>>54302133
>>
>>54285208

http://www.loper-os.org/?p=69

> Employers much prefer workers be fungible, rather than maximally productive.
>>
>>54298559
funny.
>>54296051
scala is complicated in places where lisp is simple, it just isn't as well designed
>>54297737
hi memer. everyone knows java has bretty good gc.
>>54298225
>instead of arguing over trivial things like Algol programmers and where to put their fucking curly braces
this
>>54301821
if you're using an editor that leverages any of the advantages lisp provides, no, balancing parens is not a difficult task. it's trivial enough to be mostly left to the computer.
>>54302334
(common) lisp is multiparadigm, it's pretty ambivalent to how you program. importing a whole new paradigm is only ever a library away.
>>
>>54290786
Rms doesn't like israels politics and is an atheist.
>>
Because code monkeys learn C syntax and then can't tolerate using anything else, which results in standardization of C syntax languages, which marginalizes alternatives, which propogates C syntax languages further, and so on.
>>
>>54285208
>>54287666
Nice Devil Trips, Chaim.
>>54287908
>>54287947
>>54289394
>>54290668
>>54290760
>>54290786
>>54295531
>>54295592
>>54297745
>>54298254
>>54302133
> National Socialisp
> Love it!
>>54302897
> LoperOS author is a jew-friendly faggot.
>>54303247
> a jew is a jew is a jew


Public Service Announcement

John McCarthy (the father of Lisp) was also a jew.

> (((((((John McCarthy))))))) was born in Boston, Massachusetts on September 4, 1927 to an Irish immigrant father and a Lithuanian Jewish immigrant mother,[2] John Patrick and Ida Glatt McCarthy.

https://en.wikipedia.org/wiki/John_McCarthy_(computer_scientist)
>>
>>54299166
Go to golang.org
can you find the CoC anywhere?

Now go to Rust rust-lang.org :)
>>
>>54303318
So you are an actual antisemite instead of just hating israel and their religion? Fuck off to /pol/ then faggot.
>>
>>54303351
> antisemite
I'm okay with Arabs though.
>>
So where do i start learning Lisp ?
And should i learn Lisp or Clojure or another variant ?
>>
it's a learning language not a working language
>>
>>54303785
what do you mean?
>>
>>54296187
what is Ada????

What is Java????
>>
>>54303589
The Jews only take what you give them.
You give them your money then cry about them having all your money
>>
Capitalism depends upon a workforce that is just smart enough.

If everybody is writing in a designated language like Java or C++ then they don't have to be paid as much and can easily be switched out for a Rajeesh if they demand too much from their bosses.

The fact is most curryniggers and university students are just too dumb to use Lisp, and those who are intelligent are going to be less likely to suck their bosses' Jewish cocks.

Lisp is dangerous.
>>
>>54301821
It's only shorter because the people who wrote that shit have no clue how to write lisp or scheme. To begin with the code in the three segment doesn't even implement the same thing.
Picolisp will be shorter in terms of character count (but not in terms of lines) because it's an autistic language for retards so it remapped all the usual constructs to symbols with at most 3 characters so that you can't tell what you're doing and be proud of it.
>>
>>54304407
Significantly lower-level and not formally specified.
>>
File: 1459254858382.jpg (60 KB, 495x507) Image search: [Google]
1459254858382.jpg
60 KB, 495x507
>>54297624
>he fell for the SICP meme
>>
>>54285208
Because it is useless for real-world usage.
>>
>>54295773
Using the same two characters for everything sucks the same way using actual words (e.g. Basic) for everything. There's a reason most languages use C style syntax
>>
>>54306269
What makes SICP a meme?
>>
>>54306322
Except it doesn't. It makes it trivial to refactor any piece of code, be it to move it around, replace an inline implementation by a procedure application or vice-versa, replace a raw expression by a processed expression or the converse, etc. Additionally, it makes all syntax (almost) completely consistent, which makes parsing extremely easy. In particular, sexp is the best serialization system and the only reason people prefer garbage like json or xml is because of baby duck syndrome.
>>
>>54306662
They probably cry about the examples that use math in the beginning of the book, so they call it a meme
>>
>>54306662
it's masturbatory academic wank
>>
>>54306959
You're thinking of Haskell
>>
>>54303460
Depends on what you want to do. Clojure is gaining popularity and it works well with Java. Common Lisp seems to being revived a bit with a lot of new tools and libraries. I personally prefer Scheme, specifically GNU Guile, because they have a small comfy community with a lot of opportunties.
>>
>>54307338
Too bad guile is chockfull of gotchas and bugs that are only documented in the developers' heads. For example, did you know that all literals are optimized to be the same entity, so if you have the same literal in 2 places, e.g. an empty vector that you then fill, all values based on the literal throughout the program are invalidated? No error or warning to that effect will happen and that shit is not documented.

Also, boehmgc (the gc they use) is dogshit and leaks memory if you do many allocs/deallocs, and doesn't run finalizers at the right time, so no program that manipulates large amounts of data are even remotely possible.
>>
>>54306662
It's a CS 101 book, but the "meme" is that reading it makes you a genius or enlightened.
>>
>>54295592
he said the authors of CLISP. That is a lisp implementation dumbass.
And nobody uses clisp anyway, it's no longer mantained and it has a menorah.
Nearly every lisp programmer uses sbcl
>>
>>54306322
>There's a reason most languages use C style syntax
Mostly historical, an accident of history really.
Lisp and UNIX were (sortof) competing paradigms back in the seventies. Ritchie and Thompson did something that was unseen by the time, namely, writing an OS in a high level (for the time) language, making it portable across different architectures. The lisp systems were written in assembly and the hardware in which they were was getting obsolete, so a lot of people just got used to C because there was virtually nothing else.
Some languages like js use C syntax just because it's sort of the 'standard' thing to do, but if you look at javascript, it's annoying as fucking shit man
func foo (func bar( func baz (
...
})
})
})
>>
>>54307623
>Lisp and UNIX were (sortof) competing paradigms back in the seventies.
They weren't competing at all. UNIX wasn't widely known. Books about programming never mentioned C or UNIX. LISP was a "scripting" language for AI researchers.

>Ritchie and Thompson did something that was unseen by the time, namely, writing an OS in a high level (for the time) language
You've never heard of MULTICS?

>a high level (for the time) language
At the time, C was called portable assembly.

>so a lot of people just got used to C because there was virtually nothing else.
The LISP memory hole keeps getting bigger and bigger.
>>
>>54307675
>You've never heard of MULTICS?
I don't think MULTICS was very high level, right?
>>
>>54307623
>The lisp systems were written in assembly
Wasn't the ASM itself also Lisp? Or are we not talking about Lisp machines?
>>
>>54307702
It was written in PL/I and has some impressive uses of virtual memory that still aren't used in operating systems today outside of research systems.

The Common Lisp condition system was influenced by the one from Multics PL/I.
http://www.nhplace.com/kent/Papers/Condition-Handling-2001.html
>>
>>54307725
Lisp machines are one of several types of high-level, garbage-collected graphical workstations from the 70s and 80s.

Lisp programmers don't talk about the other ones because it doesn't jive with their mythology that Lisp was more advanced than everything else.
>>
>>54307803
>Lisp programmers don't talk about the other ones
because the other ones are neither lisp nor c, retard.
>>
>>54297805
how do you handle functions with variable number of arguments without parentheses?
>>
>>54285208
Lisp is a superior programming language but the syntax is normie-repellant
>>
>>54307916
I really don't understand how, there's no syntax to speak of.
>>
>>54307874
tbH you can handle that either explicitly (list, dictionary, etc.) or via extra language syntax such as
function fn a b &rest =
let tmp = a + b in
match &rest with
| [] -> tmp
| hd :: [] -> tmp + hd
| hd::tl -> fn tmp hd tl
>>
>>54307953
See >>54298483
http://www.lispworks.com/documentation/lw51/CLHS/Body/m_loop.htm
>>
>>54307978
and fn could also be called as
fn 1 2 3 4 5 6

That is.
>>
>>54307989
Does that count as being part of the language? It seems like the sort of thing that someone just starting to learn doesn't need to know.
I've never even bothered using http://docs.racket-lang.org/guide/for.html since I can easily write loops recursively.

>>54307992
>>54307978
okay but what if I had some other function with a variable number of arguments and I wanted to use the result of that function as the 3rd argument to fn?
>>
>>54308076
list-ref &rest 3
>>
>>54308241
Err, rather 0 than 3.
>>
>>54308241
I mean this sort of situation:
(a 1 2 (b 3 4 5) 4 5)

where a and b both take a variable number of args. You can't really nest them without the parens to show where b's arguments end.
>>
>>54285208
>haible
>steingold

OY!
>>
https://en.wikipedia.org/wiki/AI_winter

>During the 1960s, the Defense Advanced Research Projects Agency (then known as "ARPA", now known as "DARPA") provided millions of dollars for AI research with almost no strings attached. DARPA's director in those years, J. C. R. Licklider believed in "funding people, not projects"[18] and allowed AI's leaders (such as Marvin Minsky, John McCarthy, Herbert A. Simon or Allen Newell) to spend it almost any way they liked.

>AI researcher Hans Moravec blamed the crisis on the unrealistic predictions of his colleagues: "Many researchers were caught up in a web of increasing exaggeration. Their initial promises to DARPA had been much too optimistic. Of course, what they delivered stopped considerably short of that. But they felt they couldn't in their next proposal promise less than in the first one, so they promised more."[20] The result, Moravec claims, is that some of the staff at DARPA had lost patience with AI research. "It was literally phrased at DARPA that 'some of these people were going to be taught a lesson [by] having their two-million-dollar-a-year contracts cut to almost nothing!'" Moravec told Daniel Crevier.[21]

>Later desktop computers built by Apple and IBM would also offer a simpler and more popular architecture to run LISP applications on. By 1987 they had become more powerful than the more expensive Lisp machines. The desktop computers had rule-based engines such as CLIPS available.[28] These alternatives left consumers with no reason to buy an expensive machine specialized for running LISP. An entire industry worth half a billion dollars was replaced in a single year.[29]
>>
>>54308076
not the same guy but the loop macro is one of the most useful things about lisp.
And as everything you learn it by using it. There are a helluva lot of things you might want to do with a loop and LOOP is versatile enough to cover a wide array of those. You can do your stuff with DO of course, but if you're ready to take the next step you look up a way to do it in LOOP.
I recently coded something like
(do ((i 0 (1+ i)
(c nil))
((>= i (length "string")) c)
(setf c (cons (char-code (elt "string" i)) c))

which is kinda ugly and somebody told me to use the loop macro
(loop for i in "string"
(collect i))

roughly.. I think that 'i in string' is faulty but you get the idea, it's mostly about the 'collect' part which does most of the magic for you, instead of having to initialize c as nil then use (setf c (cons _ c))
>>
>>54308076
Common lisp has a spec. Everything in that spec is part of the language. Scheme has specS. Anything in the r*rs specs are part of the language, and most srfi are de-facto parts of the language. Racket is its own language and no longer scheme, so its for is indeed part of the language, but the way scheme works is that you typically don't care about the standard itself as opposed to your specific language's implementation (unlike common lisp which is a lot more unified).
>>
File: 1449262409682.jpg (14 KB, 480x360) Image search: [Google]
1449262409682.jpg
14 KB, 480x360
>>54287414
>using anything but fortran for math stuff
>>
>>54307859
>the other ones are neither lisp nor c, retard.
What does that have to do with anything?
>>
>>54308937 (You)
>>
>>54308909
Fuck off, gramps. People use matlab or python for math stuff in 2016. Cuda/opencl is where it's at.
>>
>>54308909
>using fortran at all for any reason whatsoever
no
never
>>
>>54298225
>Algol programmers and where to put their fucking curly braces.
Not sure if trolling or just stupid.
>>
>>54308984
>>54309025
Matlab is slower than FORTRAN in a number of fronts and Python is absolutely useless for really complex abstract math, as not only will it be riddled with floating point miscalculations, but it will also take over 5x the time to process. And when you are testing algorithms that take days to solve, that's absolutely fucking unacceptable.

I'm so sick of this Python meme. It's a toy language and it's great for kids to learn programming. However the only people who use it professionally are kiddie hackers who are too stupid to write something in a more flexible, powerful language and hipsters who only know js and python and think they are real programmers.

As it stands Matlab is the only decent contender against Fortran and only because fortran hasn't had an update in over a decade. But the FORTRAN15 standard is shaping up to be extremely interesting.
>>
>>54285208
>"""""GNU"""""
>Copyright
>Bunch of Jews

Oy Vey
>>
>>54309300
To add onto this, the pylibs that use Fortran routines are nice and all, but once again, they are only good for retards who refuse to learn the Fortran syntax.

And that's not counting all the drawbacks that come from Python in the first place. It really is a shit language for shit programmers and should be avoided unless extremely rapid implementation is necessary. As in "Oh god I'm a fucking retard and this shit needs to be done at the end of the day and I've sat around on my ass all day shitposting on 4chan" fast.
>>
>>54309300
>I literally haven't done any numerical computations in my life
OK kid.
>>
>>54309099
void foo (void) {
bar();
}

void foo(void)
{
bar();
}

void foo(void) {
bar();
}
>>
>>54309505
>I literally haven't done any complex numerical computations in my life
500 operations in an equation ain't shit, son.
>>
>>54309538
What does that have to do with Algol?
>>
>>54309710
Indeed.
>>
>>54309300
>FORTRAN15
will I be able to do proper signal processing in fortran?

What do you think of Julia? Seems promising as a Matlab replacement
>>
>>54312268
Julia is a broken piece of garbage. Just use python, which has all the most powerful and fastest tools available.
>>
>>54309538
come on, if you ever listen or take part in any of those discussions
you have my permission to hang from a rope
Thread replies: 159
Thread images: 12

banner
banner
[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y] [Home]

All trademarks and copyrights on this page are owned by their respective parties. Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
If a post contains personal/copyrighted/illegal content you can contact me at [email protected] with that post and thread number and it will be removed as soon as possible.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com, send takedown notices to them.
This is a 4chan archive - all of the content originated from them. If you need IP information for a Poster - you need to contact them. This website shows only archived content.