Who can tell me what this program does?

Post a reply


This question is a means of preventing automated form submissions by spambots.
Smilies
:smile: :sad: :eek: :shock: :cool: :-x :razz: :oops: :evil: :twisted: :wink: :idea: :arrow: :neutral: :mrgreen:

BBCode is ON
[img] is ON
[url] is ON
Smilies are ON

Topic review
   

Expand view Topic review: Who can tell me what this program does?

by Ice Cream Jonsey » Thu Feb 15, 2007 8:53 pm

According to my calculations, the C-Interfal one, when compiled, states that it hates Hispanic people.

by bruce » Thu Feb 15, 2007 5:20 pm

Ice Cream Jonsey wrote:Did we ever get confirmation on this? Was Johnny right? Johnny's right about a lot of things, so this does not surprise me.
Pinback was right.

Bruce

by bruce » Thu Feb 15, 2007 5:19 pm

The Brainfuck example works (although you shoulda put a linefeed on there, I think), but the INTERCAL version gives me

Code: Select all

ICL778I UNEXPLAINED COMPILER BUG
        ON THE WAY TO 326
        CORRECT SOURCE AND RESUBNIT

Bruce

by Guest » Wed Feb 14, 2007 4:59 pm

by Guest » Wed Feb 14, 2007 4:57 pm

Brainfuck:
http://www.muppetlabs.com/~breadbox/bf/

++++++[>++++++++++++++++<-]>
++.--
>+++[<++++++>-]<.>[-]+++[<------>-]<
+.-
+++++++++.---------
++++++++++++++.--------------
++++++.------
>+++[<+++++++>-]<.>[-]+++[<------->-]<
+++.---
+++++++++++.-----------

C-Intercal:

PLEASE DO ,1 <- #13
DO ,1 SUB #1 <- #584
DO ,1 SUB #2 <- #837
DO ,1 SUB #3 <- #1100
DO ,1 SUB #4 <- #1356
DO ,1 SUB #5 <- #1615
DO ,1 SUB #6 <- #1824
DO ,1 SUB #7 <- #2135
DO ,1 SUB #8 <- #2383
DO ,1 SUB #9 <- #2642
DO ,1 SUB #10 <- #2892
DO ,1 SUB #11 <- #3140
DO ,1 SUB #12 <- #3361
DO ,1 SUB #13 <- #266

PLEASE DO ,2 <- #1
PLEASE DO .5 <- #0
PLEASE DO .4 <- #1

PLEASE COME FROM (1)
DO .6 <- ",1 SUB .4"~#255
DO .6 <- !6~#15'$!6~#240'
DO .6 <- !6~#15'$!6~#240'
DO .6 <- !6~#15'$!6~#240'

DO .1 <- .5
DO .2 <- .6
PLEASE DO (1010) NEXT
DO .3 <- .3~#255
DO .5 <- .6

DO ,2 SUB #1 <- .3
PLEASE READ OUT ,2

(1) PLEASE DO .4 <- ",1 SUB .4"~#3840
PLEASE GIVE UP

by Ice Cream Jonsey » Tue Feb 13, 2007 10:22 pm

Did we ever get confirmation on this? Was Johnny right? Johnny's right about a lot of things, so this does not surprise me.

by bruce » Tue Feb 13, 2007 9:01 pm

pinback wrote:Suck my balls.
Bravo.

Bruce

by pinback » Tue Feb 13, 2007 7:35 pm

Suck my balls.

by bruce » Tue Feb 13, 2007 7:15 pm

MONKEY MONKEY wrote:"BRUEC IS A FAG"?
Surprisingly close, actually.

Bruce

by MONKEY MONKEY » Sun Feb 11, 2007 1:52 pm

"BRUEC IS A FAG"?

by ICJ » Sun Feb 11, 2007 1:16 pm

draaal wrote:From nine to five, what do you work on?
I work on Oracle Portal these days. At the old job (the Assembly job) we'd get word that a particular CPU failed by doing such and such. We then had to write assembly, in as few lines as possible, that showed the error. They then sent the code and the chip off elsewhere for further investigation. It was really cool work, I wish I had a chance to do it longer.
And ya, usually languages are what is constantly reinforced; does the effort with a commercial project allow/encourage optimization, especially with taking the time to fine tune asm code?
You know what, in most places I've seen the VP of the project just wants stuff to "work" as quickly as possible, like for a demo or something, and then you optimize stuff later.

There's a story a guy told me (not at a company I worked for) of a developer who wrote a shell script to handle database records. Worked pretty good. Worked too well. He puts a for loop (or equivalent) to pause the thing for several minutes throughout the program. He says to his boss, "Well, it works... but I think I can make it run faster!" And for the next four months he does nothing but the variable he himself put in for the pause. That's software "engineering" for you.

by bruce » Sun Feb 11, 2007 1:12 pm

Johnny wrote:The first example is Brainfuck. The second example is INTERCAL. And I don't know what either one does.
Well, they're both pretty much like "Hello, world!" except they print something else. Go grab an interpreter or compiler, as appropriate, and find out!

Bruce

by draaal » Sat Feb 10, 2007 5:36 pm

From nine to five, what do you work on? And ya, usually languages are what is constantly reinforced; does the effort with a commercial project allow/encourage optimization, especially with taking the time to fine tune asm code?

by ICJ » Sat Feb 10, 2007 11:31 am

Draal wrote:Jonsey; graphics, database, driver, programming?
In terms of what I used to do in Assembly, or what I think the program does?

by Draal » Sat Feb 10, 2007 6:50 am

Jonsey; graphics, database, driver, programming?

by Lysander » Sat Feb 10, 2007 2:14 am

I would assume that it prints "Hello world!" to the screen? What am I missing?

by Ice Cream Jonsey » Sat Feb 10, 2007 12:03 am

bruce wrote:
Anonymous wrote:mov ax,cs
mov ds,ax
mov ah,9
mov dx, offset Hello
int 21h
xor ax,ax
int 21h

Hello:
db "Hello World!",13,10,"$"
That does something different than my programs.

Bruce
And seeing how I have now seemingly lost the ability to read this in MY MIND, it's clear I need to revisit Assembly, because I was quite good at it at one time. DAYUM, another thing to add to the endless list of things to do. I'll place this one towards the end.

by Johnny » Fri Feb 09, 2007 10:07 pm

The first example is Brainfuck. The second example is INTERCAL. And I don't know what either one does.

by bruce » Wed Feb 07, 2007 11:59 pm

Anonymous wrote:mov ax,cs
mov ds,ax
mov ah,9
mov dx, offset Hello
int 21h
xor ax,ax
int 21h

Hello:
db "Hello World!",13,10,"$"
That does something different than my programs.

Bruce

by Guest » Wed Feb 07, 2007 9:57 pm

mov ax,cs
mov ds,ax
mov ah,9
mov dx, offset Hello
int 21h
xor ax,ax
int 21h

Hello:
db "Hello World!",13,10,"$"

Top