text:
Write a hash function for Morse Code
Your goal is to write a hash function, that accepts morse code character and returns a hash code that you get to define.
You can be sure, passed string will be:

One of the Latin characters (A-Z) encoded into Morse Code using . and -, or
One of the digits (0-9) encoded into Morse Code using . and -, or
Empty

So, there could be any of 37 different strings passed to you.
Requirements:

The returned number should be unique for all 37 strings
For empty string the function should return 0

Score:

Initially, you have a 100 points.
You will lose

1 point for every bitwise operator in your code
2 points for every addition (subtraction) operator in your code (operators in loop clauses (e.g. inside for(;;) or while() don't count)
4 points for every multiplication (division, modulo, etc) operator
6 points for every if (else) statement
8 points for every loop statement (including loops in the called functions. You can presume that any called function has no more than one loop)
12 points for every conditional operator
200 points for using a built-in hash function

Bonuses:

If all numbers, produced by your function are less than N, you will get additional 137 - N points (of course, if the bonus is positive)

Winners:
Score matters, but be creative!

Example:
Score: 100 - 5*2 - 3*4 - 8 + (137 - 134) = 73
I know, this could be improved by removing modulo operator and make a loop starts from 1, but this is just an example
#include <iostream>
#include <map>
#include <set>

std::size_t hash_morse(const std::string& s)
{
    std::size_t ans = 0;

    for(std::size_t i = 0; i < s.size(); ++i)
    {
        ans += (s.at(i) - '-' + 2) * (i + 1) * (i + 1);
    }

    return ans % 134;
}

int main()
{
    std::map<std::string, char> m
    {
        {"",     0},
        {".-",   'A'},
        {"-...", 'B'},
        {"-.-.", 'C'},
        {"-..",  'D'},
        {".",    'E'},
        {"..-.", 'F'},
        {"--.",  'G'},
        {"....", 'H'},
        {"..",   'I'},
        {".---", 'J'},
        {"-.-",  'K'},
        {".-..", 'L'},
        {"--",   'M'},
        {"-.",   'N'},
        {"---",  'O'},
        {".--.", 'P'},
        {"--.-", 'Q'},
        {".-.",  'R'},
        {"...",  'S'},
        {"-",    'T'},
        {"..-",  'U'},
        {"...-", 'V'},
        {".--",  'W'},
        {"-..-", 'X'},
        {"-.--", 'Y'},
        {"--..", 'Z'},

        {".----",    '1'},
        {"..---",    '2'},
        {"...--",    '3'},
        {"....-",    '4'},
        {".....",    '5'},
        {"-....",    '6'},
        {"--...",    '7'},
        {"---..",    '8'},
        {"----.",    '9'},
        {"-----",    '0'}
    };

    std::map<std::size_t, std::string> hashes;

    for(const auto& elem: m)
    {
        auto hash = hash_morse(elem.first);

        if(hashes.find(hash) != hashes.end())
        {
            std::cout << "Collision" << std::endl;
            std::cout << '"' << hashes[hash] << R"(" and ")" << elem.first << '"' << std::endl;
            std::cout << "Hash: " << hash << std::endl;
            std::cout << std::endl;
        }
        else
        {
            hashes[hash] = elem.first;
        }
    }

    std::cout << "Total amount of collisions: " << (m.size() - hashes.size()) << std::endl;

    return 0;
}

Although this isn't an exact duplicate of Morse code to standard output, it's close enough that most answers will be portable both ways.

Wait, does string find/replace count as a loop?

By "binary operation" did you mean "bitwise operation"? Addition and multiplication are binary operations.

@DoorknobofSnow I think 'scanning' a string, and 'looping over' a string are semantically equivalent.

@KendallFrey, yes, it was a typo. Thanks

@DoorknobofSnow, yes. I've edited the post, thank you.

What do you mean by "Hash code" is that like a hash function (that we get to define?), or is that some term in Morse?

"•If all numbers, produced by your function less than N" What?

"•Returned number should be unique for all strings" so that means that long isn't a valid return type? because there are more than 2^64 different possible strings?

We lose points for each operation that the program performs, or for each operator that we put into our code?

This phrase doesn't make sense: "(including loops in the called functions. Guess, that function has no more than one loop)"

@McKay, 1) yes, it's a hash function. 2) It means, that function should return numbers in range [0, N) for all correct strings. 3) Unique for all strings, that satisfies given requirements. 4) For each operator that we put into our code. 5) I mean, we don't know the number of loops in the called function. So, we guess, that called function has no more than one loop.

I'm pretty sure as soon as you remove loops, you remove turing completeness(recursion is still looping).

So, the objective is to define our own hash function? The phrase "return its hash code" implies that there already exists a hash code that we are to return, but no mention of what this hash code actually is. I presume that this implication is incorrect and that we get to define our own hash function?

@McKay, yes, the goal is to define a hash function. I'm going to rephrase it, thank you.

I suggested a series of edits. That seemed easier than asking a hundred questions.

@soon You might want to clarify if all values produced by the hash should be unsigned (i.e. positive). You may also consider penalizing or disallowing direct hash look-ups.

What do you mean by "Score matters, but be creative"? I'm assuming the highest score wins, but you may want to clarify that. Is creativity solely a tie-breaker? If not, then it's not objective as is.

@soon Make sure you consider how well defined your scoring system is for more esoteric languages. Taking Brain-Flak as an example: Addition in Brain-Flak is implicit so it technically does not involve putting a addition operator in your code. At the same time it is done automatically so most of the results are not actually used. Also they way if clauses are made in Brain-Flak involves making a loop that never will run more than once. Would that count as a loop or an if/else and how should someone know for esoteric languages in general without asking?

Arguably perfect score
There are some possible loopholes in the scoring system. In particular,

8 points for every loop statement (including loops in the called functions. You can presume that any called function has no more than one loop)

According to PHP documentation,

array() is a language construct used to represent literal arrays, and not a regular function.

So it's arguable that
$hash = array(
    '' => 0,
    '.-' => -1,
    ...
);
return $hash[$morse];

contains no called functions and should score a perfect 100 + (137 - 1) = 236 points.

I think this answer demonstrates that array/hash look-up either needs to be disallowed, or heavily penalized.

I would go further and say that it demonstrates that attempting to write scoring systems based around language constructs is doomed to fail unless you restrict people to using one language.

Does array look up implicitly use a for loop or hash?

@RohanJhunjhunwala, I don't know how it's implemented. FWIW nowadays I would cast a close vote and ask OP to sandbox the question rather than posting a protest answer, but that's a sign of how the site culture has changed.

bash — 236 points
I understand there's some griping over using negative numbers, so have revised:
echo '' '[morse code]'|grep -o ' [\.-]*'|tr -t '.-' '19'|sed 's/ /0./g'|awk '{printf("%g\n",$0)}'

Will generate codes from 0.1 to 0.99999 for valid Morse Code and 0 for empty input.
e.g.
$ echo '' '. - .. -- .-.- -.-. ..... -----'|grep -o ' [\.-]*'|tr -t '.-' '19'|sed 's/ /0./g'|awk '{printf("%g\n",$0)}'
0.1
0.9
0.11
0.99
0.1919
0.9191
0.11111
0.99999

As per specs, empty input '' returns 0:
$ echo '' ''|grep -o ' [\.-]*'|tr -t '.-' '19'|sed 's/ /0./g'|awk '{printf("%g\n",$0)}'
0

Points Calculation
Starting with 100, deduct:

1 point for every bitwise operator - none
2 points for every addition (subtraction) operator - none
4 points for every multiplication (division, modulo, etc) operator - none
6 points for every if (else) statement - none
8 points for every loop statement - none
12 points for every conditional operator - none
200 points for using a built-in hash function - none

So still have 100 points.
Bonus Calculation
All numbers are less than 1 (largest is 0.99999 for ----- a.k.a. Morse Code Zero), so the bonus is 137 - 1 or 136 points, again for a total of 236 points.

bash — 236 points
echo '' '[morse code]'|grep -o ' [\.-]*'|tr -t '.-' '67'|sed 's/ /-0/g'|awk '{printf("%d\n",$0)}'

Will generate codes from -77777 to -6 for valid Morse Code and 0 for empty input.
e.g.
$ echo '' '. - ..--. -..- .--- .. -..-. .. -----'|grep -o ' [\.-]*'|tr -t '.-' '67'|sed 's/ /-0/g'|awk '{printf("%d\n",$0)}'
-6
-7
-66776
-7667
-6777
-66
-76676
-66
-77777

As per specs, empty input '' returns 0:
$ echo '' ''|grep -o ' [\.-]*'|tr -t '.-' '67'|sed 's/ /-0/g'|awk '{printf("%d\n",$0)}'
0

Points Calculation
Starting with 100, deduct:

1 point for every bitwise operator - none
2 points for every addition (subtraction) operator - none
4 points for every multiplication (division, modulo, etc) operator - none
6 points for every if (else) statement - none
8 points for every loop statement - none
12 points for every conditional operator - none
200 points for using a built-in hash function - none

So still have 100 points.
Bonus Calculation
All numbers are less than 1 (largest is 0 for an empty input), so the bonus is 137 - 1 or 136 points for a total of 236 points.

You realize that every valid hash which negates its output would automatically have a bonus of 136. Clearly, the author intended the maximum bonus to be 100.

From the specs "Your goal is to write a hash function, that accepts Morse Code characters and returns a hash code that you get to define." Standard hash codes, e.g. from md5 or sha1 can be interpreted as negative numbers, especially in languages without unsigned types like Java or Basic. There are two requirements: the returned number should be unique for all 37 strings, and for empty strings the function should return 0. Both are met.

There are 36 morse codes in this challenge. The 137-N formula should suggest that the author is referring to a positive, integer result. By skirting the requirements you are just wasting your time, because he will just write his intentions better as soon as he sees answers such as these.

Ruby 100 - 6 (one if/else) - 2 (one subtraction) = 92 + 75 (largest value is 62) = 167 (159 if string find/replace counts as looping)
code = gets.chomp
if code.empty?
  p -1
else
  p ('1' + code.gsub(/./){|c| c.ord - 45 }).to_i(2)
end

Simply does a find/replace on the string, but replaces each character with its ASCII code - 45. This turns - into 0 and . into 1. It then prepends a 1 (to handle leading zeroes) and parses this string as binary.

Same comment as to primo: 137 - 63 = 74 for the bonus. (And clarification to question says that find/replace counts as looping).

GolfScript (143 164 192 points)
I was slightly wrong about the relationship with the other Morse question: this one is much much simpler.
2base

scores 100 - 8 points for an implicit loop = 92, with no bonus.
2base 87%

scores 100 - 4 points for a modulo - 8 points for an implicit loop + (137 - 82) bonus points for a total of 143 points.
That has two parameters which can potentially be optimised to improve the bonus. The best I've found so far is
46base 62%

for N=61 and a total of 164 points.
But it's possible to do even better.
2base MAGIC_STRING=

scores 100 - 8 points for an implicit loop + (137 - 37) bonus points for a total of 192 points, where MAGIC_STRING is a suitable 1427-character string literal:
"\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x1E\x0F\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x17\x18\v\x13\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x19\x11\x15\x0E!\x1C\x1F\x1D\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\e$#\r\"\f\x14\x1A\x00\x16\x00\x10 \x12\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\n\x00\t\x00\x00\x00\b\x00\x00\x00\x00\x00\x00\x00\a\x02\x00\x00\x00\x00\x00\x00\x00\x03\x00\x00\x00\x04\x00\x05\x06"

@primo, that's what comes of copying the string from a command window output rather than redirecting to a file and copying from the file. = is not a looping function: it's an array indexing operation. No language that I know of implements those with a loop.

You're right. I Confused it with find.

Perl - score = 165
print~-oct'0b1'.<>=~y/.-/10/r

Re-interpretting morse as binary, with a 1 prepended.
Score break-down

-1 - bitwise inversion (~)
-8 - loop statement (y)
+74 - the largest value produced is 62

I make 137 - 63 = 74 for the bonus.

180+ should be possible. Go go magic formula grinder.

Actually, yes, you're right...

Scheme:
Initial 100 points and it has no reduction since there was no mention of switch/case there and the / is part of the number not an operator..
The output is a rational number between 0 and 1. Extra score would be 137-1=136.
Total score: 236
(define (hash-morse-code code)
  (case code
    (("") 0)
    ((".-") 1)
    (("-...") 1/2)
    (("-.-.") 1/3)
    (("-..") 1/4)
    ((".") 1/5)
    (("..-.") 1/6)
    (("--.") 1/7)
    (("....") 1/8)
    (("..") 1/9)
    ((".---") 1/10)
    (("-.-") 1/11)
    ((".-..") 1/12)
    (("--") 1/13)
    (("-.") 1/14)
    (("---") 1/15)
    ((".--.") 1/16)
    (("--.-") 1/17)
    ((".-.") 1/18)
    (("...") 1/19)
    (("-") 1/20)
    (("..-") 1/21)
    (("...-") 1/22)
    ((".--") 1/23)
    (("-..-") 1/24)
    (("-.--") 1/25)
    (("--..") 1/26)
    ((".----") 1/27)
    (("..---") 1/28)
    (("...--") 1/29)
    (("....-") 1/30)
    ((".....") 1/31)
    (("-....") 1/31)
    (("--...") 1/32)
    (("---..") 1/33)
    (("----.") 1/34)
    (("-----") 1/35)))

(hash-morse-code "...") => 1/19

Java - 100 + 136 = 236
public static int hashMorse(String toHash) {
    switch (toHash){
        case ".-": //A
            return -36;
        case "-...": //B
            return -35;
        case "-.-.": //C
            return -34;
        case "-..": //D
            return -33;
        case ".": //E
            return -32;
        case "..-.": //F
            return -31;
        case "--.": //G
            return -30;
        case "....": //H
            return -29;
        case "..": //I
            return -28;
        case ".---": //J
            return -27;
        case "-.-": //K
            return -26;
        case ".-..": //L
            return -25;
        case "--": //M
            return -24;
        case "-.": //N
            return -23;
        case "---": //O
            return -22;
        case ".--.": //P
            return -21;
        case "--.-": //Q
            return -20;
        case ".-.": //R
            return -19;
        case "...": //S
            return -18;
        case "-": //T
            return -17;
        case "..-": //U
            return -16;
        case "...-": //V
            return -15;
        case ".--": //W
            return -14;
        case "-..-": //X
            return -13;
        case "-.--": //Y
            return -12;
        case "--..": //Z
            return -11;
        case ".----": //1
            return -10;
        case "..---": //2
            return -9;
        case "...--": //3
            return -8;
        case "....-": //4
            return -7;
        case ".....": //5
            return -6;
        case "-....": //6
            return -5;
        case "--...": //7
            return -4;
        case "---..": //8
            return -3;
        case "----.": //9
            return -2;
        case "-----": //0
            return -1;
        default:
            return 0;
    }
}

All those - signs don't count; they stand for the literal number. If you want to count them, then I'll just replace all those numbers with the binary literal (no minuses then).
Switches are free according to the question; neither an if nor an else. If you don't want switches, I'll just replace it with a HashMap
The largest possible number is 0, for the empty string or invalid strings.

Don't like negative numbers? This works (score of 200):
public static int hashMorse(String toHash) {
    switch (toHash){
        case ".-": //A
            return 36;
        case "-...": //B
            return 35;
        case "-.-.": //C
            return 34;
        case "-..": //D
            return 33;
        case ".": //E
            return 32;
        case "..-.": //F
            return 31;
        case "--.": //G
            return 30;
        case "....": //H
            return 29;
        case "..": //I
            return 28;
        case ".---": //J
            return 27;
        case "-.-": //K
            return 26;
        case ".-..": //L
            return 25;
        case "--": //M
            return 24;
        case "-.": //N
            return 23;
        case "---": //O
            return 22;
        case ".--.": //P
            return 21;
        case "--.-": //Q
            return 20;
        case ".-.": //R
            return 19;
        case "...": //S
            return 18;
        case "-": //T
            return 17;
        case "..-": //U
            return 16;
        case "...-": //V
            return 15;
        case ".--": //W
            return 14;
        case "-..-": //X
            return 13;
        case "-.--": //Y
            return 12;
        case "--..": //Z
            return 11;
        case ".----": //1
            return 10;
        case "..---": //2
            return 9;
        case "...--": //3
            return 8;
        case "....-": //4
            return 7;
        case ".....": //5
            return 6;
        case "-....": //6
            return 5;
        case "--...": //7
            return 4;
        case "---..": //8
            return 3;
        case "----.": //9
            return 2;
        case "-----": //0
            return 1;
        default:
            return 0;
    }
}

HashMap definitely isn't free. It has loops in both put and get.

@PeterTaylor what about python's dictionaries? Can I use those?

Probably, although then it's going to look very similar to my PHP answer. switch is more interesting because no-one else had done it.

Java - 100 + 136 = 236
public static int hash(String morse){
    try{
        morse.charAt(0);
    }catch (IndexOutOfBoundsException e){
        return 0;
    }
    return Integer.parseInt("-1" + help(morse), 2);
}
private static String help(String morse) {
    int a = 0;
    try {
        a = (int) morse.charAt(0);
    } catch (IndexOutOfBoundsException e) {
        return "";
    }
    a = Integer.parseInt(String.valueOf(Integer.toString(a, 2).charAt(4)));
    return a + help(morse.substring(1));
}

call hash(someString); to use this function. I'm working on a loop-free alternative to Integer.parseInt and Integer.toString.
I avoided the penalties by:

using recursion instead of loops
using Strings and String concatenation instead of numbers

So I get 100 + 136 as the largest output is 0.

They use loops. So does String.format.

JavaScript, 217pts
replace : Minus 8pts (loop)
replace : Minus 8pts (loop)
/ 100000: Minus 4pts (division)

100 - 20 = 80 + (137 - 0) = 217
function mc2(s) {
    return s.replace(/\./g,'1').replace(/-/g,'2') / 100000
}

JavaScript 199pts
for     : Minus  8pts (loop)
r+=     : Minus  2pts (addition)
(c>'-') : Minus  6pts (if)
c>'-'   : Minus 12pts (conditional operator)
:2      : Minus  6pts (else)
r/      : Minus  4pts (division)

100-38pts = 62pts + (137-0) = 199pts
function mc2(s) {
    r=''
    for(i=0;(c=s[i]);i++)r+=(c>'-')?1:2
    return r/100000
}

Python, 236
Now, Peter Taylor claims to have a perfect score.  But really, he's only got 200.  Negative numbers all being smaller than zero, my bonus is 137-1, so this solution is 36 points better.
F = lambda s:-eval(''.join([
'12340'[s[0:].find('-')],'12340'[s[0:].find('.')],
'12340'[s[1:].find('-')],'12340'[s[1:].find('.')],
'12340'[s[2:].find('-')],'12340'[s[2:].find('.')],
'12340'[s[3:].find('-')],'12340'[s[3:].find('.')],
'12340'[s[4:].find('-')],'12340'[s[4:].find('.')]]))

Does find not contain a loop?

Ah, missed the bit on functions.

Waitaminute.  We can assume "no more than one"?  How 'bout I assume zero, which is certainly no more than one, and don't change my answer in the least.

I don't think that's a plausible interpretation.

I don't think so either, but that's what a literal reading of the rules suggests.  I think I'm being generous, actually, by not updating my score to reflect an assumption of a negative number of loops in the function calls.


text:
Generate lists in which every sublist has a unique element
The problem is defined as follows:
Create a function that takes an integer and returns a list of integers, with the following properties:

Given a positive integer input, n, it produces a list containing n integers ≥ 1.
Any sublist of the output must contain at least one unique element, which is different from all other elements from the same sublist. Sublist refers to a contiguous section of the original list; for example, [1,2,3] has sublists [1], [2], [3], [1,2], [2,3], and [1,2,3].
The list returned must be the lexicographically smallest list possible.

There is only one valid such list for every input. The first few are:
f(2) = [1,2]         2 numbers used
f(3) = [1,2,1]       2 numbers used
f(4) = [1,2,1,3]     3 numbers used

Wouldn't [1,2,1] be incorrect because elements 1 are the same?

I'm sorry, you're going to have to better define "lexicographically" better over the solution space.

e.g. why isn't [0,1] better than [1,2] for f(2)?

@Timtech: No, because the first 1 is in another sublist than the second 1. A sublist is a contiguous section of the original list, so there are three sublists: [1] [1,2] [1]

@McKay: Thanks for clarifying. I’ve added the constraint ≥ 1. (By the way, I didn’t post the problem; OP: I hope you’re OK with my edits)

@ProgramFOX Okay, I get it now.

Does 'lexicographically' mean 'with the lowest possible sum'?

@Oberon it means the natural sorting order. For example [1, 1, 2] < [1, 2, 1] when compared element by element.

shouldn't f(3) be [1,2] ([[1],[2],[1,2]]) and f(4) be [1,1,2] ([[1],[1],[2],[1,2]) ?

@ProgramFOX and everyone who voted to close this, since this question is tagged as code-golf I think we do have an objective winning criterion?

Ow, read that the list needs to answer list needs to be n long, that makes it even easier

GolfScript (20 18 chars)
{,{.)^2base,}%}:f;

This is a simple binary ruler function, A001511.
Equivalently
{,{).~)&2base,}%}:f;
{,{~.~)&2base,}%}:f;
{,{).(~&2base,}%}:f;
{,{{1&}{2/}/,)}%}:f;

Thanks for primo for saving 2 chars.

).~)& -> .)^ for 2.

APL, 18
{+⌿~∨⍀⊖(⍵/2)⊤2×⍳⍵}

1 + number of trailing zeros in base 2 of each natural from 1 to N.
Example
      {+⌿~∨⍀⊖(⍵/2)⊤2×⍳⍵} 32
1 2 1 3 1 2 1 4 1 2 1 3 1 2 1 5 1 2 1 3 1 2 1 4 1 2 1 3 1 2 1 6

Sclipting, 26 23 characters
감⓶上가增❷要❶감雙是가不감右⓶增⓶終終丟丟⓶丟終并

This piece of code generates a list of integers. However, if run as a program it will concatenate all the numbers together. As a stand-alone program, the following 25-character program outputs the numbers separated by commas:
감⓶上가增❷要감嚙是가不⓶增⓶終終丟丟⓶丟껀終合鎵

Example output:
Input: 4
Output: 1,2,1,3
Input: 10
Output: 1,2,1,3,1,2,1,4,1,2

Jelly, 4 bytes
ọ€2‘

Try it online!
Explanation
ọ€2‘
 €      For each integer from 1 to {the command-line argument}
ọ         calculate the number of trailing zeroes in base
  2         2
   ‘    and increment {each resulting integer} {and output them}

Haskell, 40 characters
n&p=n:p++(n+1)&(p++n:p)
f n=take n$1&[]

Example runs:
λ: f 2
[1,2]
λ: f 3
[1,2,1]
λ: f 4
[1,2,1,3]
λ: f 10
[1,2,1,3,1,2,1,4,1,2]
λ: f 38
[1,2,1,3,1,2,1,4,1,2,1,3,1,2,1,5,1,2,1,3,1,2,1,4,1,2,1,3,1,2,1,6,1,2,1,3,1,2]

Python 2.7, 65 characters
print([len(bin(2*k).split('1')[-1]) for k in range(1,input()+1)])

The number of trailing zeros in 2, 4, 6, ..., 2n.

Japt, 9 bytes
õÈ¤q1 ÌÊÄ

Try it

Haskell, 29 bytes
(`take`t)
t=1:do x<-t;[x+1,1]

Try it online!

source: Stack Exchange

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/

sort: votes


text:
Interpret a circuit diagram
Your challenge is to interpret a circuit diagram, complete with logic gates.
Logic gates (you don't actually need to know what these do / are to complete this challenge):

and gate: a
or gate: o
nand gate: A
nor gate: O
xor gate: x
xnor gate: X
not gate: ~

Each gate but the last one takes two inputs. Inputs are from a . in the top left and bottom left corners of the 3 by 3 square centered on the gate. For not, the input is directly to its left. Output is to a . directly to the right.
Wires are represented by -|\/.=

- contacts two wires, one to the right, and one to the left: c-c
| contacts two wires, one above, and one below:
c
|
c

/ and \ work as follows:
c        c
 \      /
  c    c

. contacts every surrounding wire:
ccc
c.c
ccc

= is special; it connects adjacent wires across it:
-=-

connects the two wires. In the following
\|/
-=-
/|\

each opposite wire is connected with each other, but not the others (this is where it differs from .).
In order for current to flow, two wires must both be connected to the other one, so in |-, current does not flow.

Example of wiring:
      .-.
     =   \
 .--. .---=---
-.   =     .--
 .--. .-------

the input is split into two wires and then split into three. In this split, the bottom wire moves to the middle, and the downwards split of the top wire appears on the bottom. Next, the top of the three wires is moved to the middle.
Sample wiring with gates:
--.
   o..~..
--.      o.---
   a.---.
--.

Input format:

each input wire will be labeled with a digit. At the end (right before newline), each output will be labeled with : (and the wire will always go right into it, ie -: or .: or =:)
the input will always be valid; there will be no loops or wires joining together without a gate. Note that there can be wires with loose ends.
= will be used only when necessary.

Output format:

each input is referenced with the corresponding number.
an expression is outputted. For example, if the wires compute input 1 and input 2, the output is 1a2.
whatever functions outputted must correspond to the logic gates at the beginning.
to show not, put the ~ before the correct place.
for multiple functions, use parentheses to show the order of execution. Parentheses can also be used when there is only a single function. For example,
1-.~.-.
       A.~.-:
      .
2-.  /
   x.
3-.

has one possible output of ~((2x3)A(~1))
multiple outputs must be separated by a newline (or equivalent)

Sample input:
1--.---.
    x.  \
2--.  x.-=---------.
     .    .~.       X.--.
3---. .      a.----.   /
       O.~.-.       \ /
      .              =
4-.  /              / .-:
   X.              .----:
5-.

One possible corresponding output:
(~1)a(~(3O(4X5))
((1x2)x3)X((~1)a(~(3O(4X5))))

Oooohhhh, interesting! I'll give it a shot.

I am foreseeign an interesting exolang coming out of this, if we extend it in a way to make it Turing-complete.

In case of a "compiler error" (i.e. malformed input wiring) what should the interpreter do?

And, if I connect directly two inputs? Or connect directly two outputs? Or input open lines to the output?

Would the . to the right (output) of the first x in the sample input be valid? That . is being used to split a wire, which (in the other direction) means it's being used to join two wires together. Without a gate. This is done several times. Also, the triangle of .s coming off 3 is effectively a loop. Unless we're supposed to treat the . inputs of a gate differently from a . wire, in which case the . coming off 1 is weird.

@Victor This is not an interpreter as much as a parser. The program can do anything; just assume the input will be valid. Also, you cannot connect two inputs: "wires joining together without a gate". How do you connect two outputs? You can also assume that every output leads back to some input.

@Bob splitting wires is definitely okay, but joining is not (think about it in the logic diagram sense). The sample input is totally valid. The triangle of .s does not touch itself, so it is not a loop. If the . . there was ..., then it would be a loop, so that would not be valid. The . coming off of gates means that every gate will output to a ., which is also a wire.

@Quincunx I'm sorry, I don't understand. If you split a wire, you effectively have three wires - and from a different perspective that could be seen as two wires joining into one. Unless the gate inputs are strictly one-way... that's probably it, isn't it? As for the triangle, yes, I see how I misread it now. I'll give it another shot (with the input-only constraint) later.

@Bob That's right, gate inputs are strictly one way.

@Victor This is already similar. But I went ahead and created another one

@Quincunx, in your Circuit Diagram new language, are constructs like flip-flops allowed?

@Victor I'm working out the kinks.

Python 2488 1567 806 706 697 657 653
Yay for gzip + exec!
import zlib,base64;exec zlib.decompress(base64.b64decode('eNp1U8FuqzAQvPMV7sm2gBSuuFupX9BLD5UoBxNMMAkEgQmJVPXb364Daiu9ntaznt2dWYzthvPo2HSbgsrU7E3so0FmAWtgnyeFshjSImC2Zs1Tws4js/fQPMPJ9KKTlFrPeVPIbDRuHnvOA3YByuS2UCNwrloYqOMRQ1ooDY0qwaoKRJxGSZRKP+QCwBn/0YRyzPYcYq77irUATVbGcIytGkN4E7mOyiLayx/MT888AthMx9DGDTLj/zIfPz44emUGqC/Zoio1UdFzohzFp0TNNA7xQhFxDWJiNGNG98L54yLVYUsv3+kZx9G8/uyEoQFk8NELrDeIIggf5Cb3b3/I3nnFNdZe0QOrCHl4+4ZsgVyH16gMb4XHq4IrwA0gkV7kAwyZH7Fs7f0S/O7IbnZX7jelzy+v13f8LsAFD0kVfrQyTklZyCUPL+F2Ef66WHug7i9f/bWyfnOIsrNTZQ/WCXxCcAnY/QmwMeggLwIyeCKD+FB3k6tsj/K6nR4G01fiZCcnTlIGBkw/d2bUzvgSG2kqMvhOkU+ZNirvGS1XgyWKy/xS2TDa3uE/kNuoJX0UC/kP8j/kmA=='))

Limitations and assumptions
As it is, only up to 9 inputs are supported - multiple digits are not handled correctly. As the spec indicates that inputs are labelled with a digit, not a number, this is allowed.

Input and output
Input is taken via standard in, and output is via standard out.

Testing
Sample input and output:
1--.---.
    x.  \
2--.  x.-=---------.
     .    .~.       X.--.
3---. .      a.----.   /
       O.~.-.       \ /
      .              =
4-.  /              / .-:
   X.              .----:
5-.

(~(1))a(~((3)O((4)X(5))))
(((1)x(2))x(3))X((~(1))a(~((3)O((4)X(5)))))

Tested here: http://ideone.com/gP4CIq

The algorithm
It's basically a rather naive DFS from the outputs. For each output, it starts from the character one to its left and traces the wire, branching (and adding to the expression) at every gate. When it reaches an input, it adds it to the expression and backtracks to the last point it branched, since we can be sure that branching is not possible without a gate. And of course any invalid cases are discarded. Nothing really special to it - and therefore it's likely longer than it could have been.

Notes
Size could probably be reduced a fair bit with some restructuring, but I've spent enough time on this for today. The manually golfed version was the one compressed.
The gzip compression makes golfing interesting, because certain caching (e.g. d=(-1,0,1)) actually takes more space than letting the compression algorithm take care of it. However, I opted to golf the manual version as far as possible rather than optimising for compression.

Manually golfed (909 895 840 803):
import sys
def T(c,p):
 h=c[0];i=c[1]
 if h<0 or i<0 or h>=len(m)or i>=len(m[h]):return''
 v=m[h][i];r='';j=p[0];k=p[1];a=h;b=i;d=(-1,0,1)
 if v==' ':return''
 if v in'=-'and j==h:b-=k-i;r+=T([a,b],c)
 if v in'=|'and k==i:a-=j-h;r+-T([a,b],c)
 if v in'=/\\':
  e=j==h or k==i;s=j-h>0;t=j-h<0;u=k-i>0;w=k-i<0;f=(s and u)or(t and w);g=(s and w)or(t and u)
  if not(e or v=='/'and f or v=='\\'and g):a-=j-h;b-=k-i;r+=T([a,b],c)
 if v=='.':
  for x in d:
   for y in d:
    w=[a+x,b+y]
    if not(x==y==0)and w!=p:r+=T(w,c)
 if j==h and k-i>0:
  if v in'aoAOxX':r='('+T([a-1,b-1],c)+')'+v+'('+T([a+1,b-1],c)+')'
  if v=='~':r='~('+T([a,b-1],c)+')'
 if v.isdigit():r=v
 return r
m=[]
for l in sys.stdin:
 m.append(list(l))
e=enumerate
for i,a in e(m):
 for j,b in e(a):
  if b==':':
   print T([i,j-1],[i,j])

Full ungolfed (2488):
import sys

def findOuts(c):
    for i, iVal in enumerate(c):
        for j, jVal in enumerate(iVal):
            if jVal == ':':
                yield [i, j]

def trace(pos, prev):
    if pos[0] < 0 or pos[1] < 0 or pos[0] >= len(circuit) or pos[1] >= len(circuit[pos[0]]):
        return ''
    val = circuit[pos[0]][pos[1]]
    if val == ' ':
        return ''
    next = pos[:]
    ret = ''
    if val in '=-':
        if prev[0] == pos[0]:
            next[1] -= prev[1] - pos[1]
            ret += trace(next, pos)
    if val in '=|':
        if prev[1] == pos[1]:
            next[0] -= prev[0] - pos[0]
            ret += trace(next, pos)
    if val in '=/\\':
        # top-bottom, left-right
        tblr = prev[0] == pos[0] or prev[1] == pos[1]
        # top-left, bottom-right
        tlbr = (prev[0] - pos[0] == 1 and prev[1] - pos[1] == 1) or (prev[0] - pos[0] == -1 and prev[1] - pos[1] == -1)
        # top-right, bottom-left
        trbl = (prev[0] - pos[0] == 1 and prev[1] - pos[1] == -1) or (prev[0] - pos[0] == -1 and prev[1] - pos[1] == 1)
        if not ((val == '/' and (tlbr or tblr)) or (val == '\\' and (trbl or tblr)) or (val == '=' and tblr)):
            next[0] -= prev[0] - pos[0]
            next[1] -= prev[1] - pos[1]
            ret += trace(next, pos)

    if val == '.':
        for x in (-1,0,1):
            for y in (-1,0,1):
                if x == y == 0:
                    continue

                w = [next[0] + x, next[1] + y]
                if w == prev:
                    continue

                # only one of them should return anything
                ret += trace(w, pos)

    # assumption that a logic gate always has a . on its connections, as according to spec
    if val in 'aoAOxX':
        # only from the right/output
        if not (prev[0] == pos[0] and prev[1] == pos[1] + 1):
            return ret
        ret = '(' + trace([next[0] - 1, next[1] - 1], pos) + ')' + val + '(' + trace([next[0] + 1, next[1] - 1], pos) + ')'

    if val == '~':
        # only from the right/output
        if not (prev[0] == pos[0] and prev[1] == pos[1] + 1):
            return ret
        ret = '~(' + trace([next[0], next[1] - 1], pos) + ')'

    if val in '123456789':
        ret = val

    return ret

circuit = []
for line in sys.stdin.readlines():
    # padding added to prevent index out of bounds later
    circuit.append(list(line))

for out in findOuts(circuit):
    next = out[:]
    next[1] -= 1
    print trace(next, out)

What is DFS? Also, working backwards from the output is exactly what I was thinking of.

@Quincunx Depth-first-search. Basically, recursion (or otherwise using a LIFO construct, a stack) and travelling as far as possible along a path until it hits a dead end or the goal, at which point it returns to the last point of divergence and tries the other paths.

Good assumption on the inputs. That is exactly what I meant (and I tried to word it to suggest that). However, does your program work with 0 as a digit? How about swapped ordering so that 2 comes before 1, etc.

@Quincunx I'm using Python's .isdigit(), which is effectively equivalent to the regex [0-9] as far as I can tell. Is that correct according to your spec? What do you mean by swapped ordering? The way it's implemented, it'll head on the upwards branch of any logic gate first, but there's no guarantee of ordering of inputs.

isdigit() is consistent. Swapped ordering means something like 2 as the first input, and 1 as the second input (sorted vertically).

@Quincunx In that case - no, it doesn't care what order, it'll just keep going until it hits a digit, any digit. It also doesn't care if there's multiple instances of a digit (assumes program is valid according to spec). Handling multi-digit numbers would be fairly trivial, I just didn't bother (simply keep traveling left on any digit until it reaches the end, building up a number as you go - something like ret = trace([next[0], next[1] - 1], pos) + val on the ungolfed one).

Then your solution is completely valid. Good job!

Java: 1523 1512 chars
import java.util.*;class W{int v=99;Map<Integer,String>t;boolean k;public static void main(String[]y){new W().d();}W(){try{java.io.InputStream i=new java.io.File("r").toURL().openStream();t=new HashMap<>();int a=0,x=0,y=0;while((a=i.read())>-1){if(a==10){y++;x=0;continue;}q(x,y,(a>47&a<58?"!":"")+(char)a);x++;}}catch(Exception e){}}void d(){while(!k){k=!k;for(Map.Entry<Integer,String>g:t.entrySet())e(g.getKey(),g.getValue());}for(String b:t.values())if(b.startsWith("$"))System.out.println(b.substring(1));}void e(int a,String s){if(s==null||!s.startsWith("!"))return;int x=a/v,y=a%v;s=s.substring(1);b(s,x,y,x-1,y+1);b(s,x,y,x,y+1);b(s,x,y,x+1,y+1);b(s,x,y,x-1,y);b(s,x,y,x+1,y);b(s,x,y,x-1,y-1);b(s,x,y,x,y-1);b(s,x,y,x+1,y-1);}void b(String p,int m,int n,int x,int y){String s=t.get(x*v+y);if(s==null)return;boolean g=y==n+1;boolean h=y==n-1;boolean i=x==m+1;boolean j=x==m-1;if(z(s,"-=")&n==y){if(i)b(p,x,y,x+1,y);if(j)b(p,x,y,x-1,y);}if(z(s,"|=")&m==x){if(g)b(p,x,y,x,y+1);if(h)b(p,x,y,x,y-1);}if(z(s,"/=")){if(j&g)b(p,x,y,x-1,y+1);if(i&h)b(p,x,y,x+1,y-1);}if(z(s,"\\=")){if(i&g)b(p,x,y,x+1,y+1);if(j&h)b(p,x,y,x-1,y-1);}if(z(s,".")){q(x,y,"!"+p);u();}if(z(s,"~")){q(x,y,"!~("+p+")");u();}if((s.charAt(0)=='%'&n==y-1)|(s.charAt(0)=='&'&n==y+1)){q(x,y,"!("+p+")"+s.charAt(1)+"("+s.substring(2)+")");u();}if(z(s,"OoAaXx")){q(x,y,(n==y+1?"%":"&")+s+p);u();}if(z(s,":")){q(x,y,"$"+p);u();}}void q(int x,int y,String z){t.put(x*v+y,z);}void u(){k=false;}boolean z(String s,String c){return c.indexOf(s)>-1;}}

It gives this output for the sample input:
(~(((5)X(4))O(3)))a(~(1))
((~(((5)X(4))O(3)))a(~(1)))X(((2)x(1))x(3))

In order to squeeze its size:

It does not do any error checking, error handling or input validation, assuming that the input is always valid.
Is limited to 99 lines of input.
Its input file must be called just r, without any file extension in the name.
It does not makes any effort to detect if the parenthesis are or aren't necessary. It assumes that they always are necessary, and since this assumption is false, there is a lot more parenthesis than needed, but since this does not makes it fail the spec anyway, it is no problem.
The order of the parameters to each binary operator is in general unpredictable, as it depends on the velocity that the values are propagated and from cell scanning order. But since all the binary operators are commutative, this should be no problem.

I am sure that it should be possible to reduce it more, but just a bit.
The interpreter is implemented in the form of some sort of cellular automata. It scans the entire field setting values, repeating it as many times as needed until no changes are detected.
Here is an ungolfed version:
import java.util.*;

class Wiring {

    int maxLines = 99;
    Map<Integer, String> circuitState;
    boolean finished;

    public static void main(String[] args) {
        new Wiring().interpret();
    }

    Wiring() {

        try {
            // Always read the input from the "r" file, and do not check if it even
            // exists. BTW, the toURL() method is deprecated, but we don't care about
            // this in code-golfing.
            java.io.InputStream stream = new java.io.File("r").toURL().openStream();

            circuitState = new HashMap<>();
            int byteRead = 0, cellX = 0, cellY = 0;

            while ((byteRead = stream.read()) > -1) {

                // Check for line break;
                if (byteRead == 10) {
                    cellY++;
                    cellX = 0;
                    continue;
                }

                // Populate the circuit cell. Precede numbers with an exclamation mark.
                setCircuitCell(cellX, cellY, (byteRead >= '0' & byteRead <= '9' ? "!" : "") + (char) byteRead);
                cellX++;
        } catch (Exception e) {
        }
    }

    void interpret() {
        while (!finished) {
            finished = !finished; // i.e. finished = false;
            for (Map.Entry<Integer, String> entry : circuitState.entrySet()) {
                analyzeCell(entry.getKey(), entry.getValue());
            }
        }

        // Now print the output. To do that scan for cells marked with "$".
        for (String cell : circuitState.values()) {
            if (cell.startsWith("$")) System.out.println(cell.substring(1));
        }
    }

    void analyzeCell(int cellIndex, String cellValue) {
        // Only the cells with a value marked with "!" are worth to analyze.
        if (cellValue == null || !cellValue.startsWith("!")) return;

        // Convert the cellIndex to a bidimensional coordinate.
        int x = cellIndex / maxLines, y = cellIndex % maxLines;

        // Remove the "!".
        cellValue = cellValue.substring(1);

        // Propagate the cell value to neighbouring cells.
        propagateCellData(cellValue, x, y, x - 1, y + 1);
        propagateCellData(cellValue, x, y, x, y + 1);
        propagateCellData(cellValue, x, y, x + 1, y + 1);
        propagateCellData(cellValue, x, y, x - 1, y);
        propagateCellData(cellValue, x, y, x + 1, y);
        propagateCellData(cellValue, x, y, x - 1, y - 1);
        propagateCellData(cellValue, x, y, x, y - 1);
        propagateCellData(cellValue, x, y, x + 1, y - 1);
    }

    void propagateCellData(String cellValue, int sourceX, int sourceY, int targetX, int targetY) {
        String targetContent = circuitState.get(targetX * maxLines + targetY);

        // If the target cell does not exist, just ignore.
        if (targetContent == null) return;

        boolean targetBelowSource = targetY == sourceY + 1;
        boolean targetAboveSource = targetY == sourceY - 1;
        boolean targetRightToSource = targetX == sourceX + 1;
        boolean targetLeftToSource = targetX == sourceX - 1;

        // Propagate horizontally through wires.
        if (isStringContained(targetContent, "-=") & sourceY == targetY) {
            if (targetRightToSource) propagateCellData(cellValue, targetX, targetY, targetX + 1, targetY);
            if (targetLeftToSource) propagateCellData(cellValue, targetX, targetY, targetX - 1, targetY);
        }

        // Propagate vertically.
        if (isStringContained(targetContent, "|=") & sourceX == targetX) {
            if (targetBelowSource) propagateCellData(cellValue, targetX, targetY, targetX, targetY + 1);
            if (targetAboveSource) propagateCellData(cellValue, targetX, targetY, targetX, targetY - 1);
        }

        // Propagate in the diagonal x=-y.
        if (isStringContained(targetContent, "/=")) {
            if (targetLeftToSource & targetBelowSource) {
                propagateCellData(cellValue, targetX, targetY, targetX - 1, targetY + 1);
            }
            if (targetRightToSource & targetAboveSource) {
                propagateCellData(cellValue, targetX, targetY, targetX + 1, targetY - 1);
            }
        }

        // Propagate in the diagonal x=y.
        if (isStringContained(targetContent, "\\=")) {
            if (targetRightToSource & targetBelowSource) {
                propagateCellData(cellValue, targetX, targetY, targetX + 1, targetY + 1);
            }
            if (targetLeftToSource & targetAboveSource) {
                propagateCellData(cellValue, targetX, targetY, targetX - 1, targetY - 1);
            }
        }

        // If we got a dot, store the value there.
        // Do not forget to mark it with "!", so we can rescan it later.
        if (isStringContained(targetContent, ".")) {
            setCircuitCell(targetX, targetY, "!" + cellValue);
            markThatStateChanged();
        }

        // If we got a "~", store the inverted value there.
        // Do not forget to mark it with "!", so we can rescan it later.
        if (isStringContained(targetContent, "~")) {
            setCircuitCell(targetX, targetY, "!~(" + cellValue + ")");
            markThatStateChanged();
        }

        // If we found a binary logical port with one of the values set and
        // we can set the another value, do it. Use "%" and "&" to know which
        // one was already defined.
        // BTW, do not forget to mark it with "!", so we can rescan it later.
        if ((targetContent.charAt(0) == '%' & sourceY == targetY - 1)
                | (targetContent.charAt(0) == '&' & sourceY == targetY + 1))
        {
            setCircuitCell(targetX, targetY,
                    "!(" + cellValue + ")"
                    + targetContent.charAt(1)
                    + "(" + targetContent.substring(2) + ")");
            markThatStateChanged();
        }

        // Found a binary logical port without any value setted, so set it.
        // Use "%" and "&" to mark which one was setted.
        if (isStringContained(targetContent, "OoAaXx")) {
            setCircuitCell(targetX, targetY, (sourceY == targetY + 1 ? "%" : "&") + targetContent + cellValue);
            markThatStateChanged();
        }

        // If we found an output, store the value there.
        // Mark it with "$", so we will print it in the future.
        if (isStringContained(targetContent, ":")) {
            setCircuitCell(targetX, targetY, "$" + cellValue);
            markThatStateChanged();
        }
    }

    void setCircuitCell(int cellX, int cellY, String cellContents) {
        circuitState.put(cellX * maxLines + cellY, cellContents);
    }

    void markThatStateChanged() {
        finished = false;
    }

    boolean isStringContained(String searchingString, String searchTarget) {
        return searchTarget.indexOf(searchingString) > -1;
    }
}

Tiny bit cheaper to use try{}catch(Exception e){} rather than two throws Exception. There's probably other things, but I have no idea how to golf Java.

@Bob Thanks, your suggestion made me reduce it 7 characters. Also, I could reduce further 4 more.

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/


text:
Valentine's day greetings card generator
Create a program that, given a name as input, will generate a Valentine’s day greeting card featuring that name, with its source code also having a Valentine’s day theme. The greeting can be either ASCII art or a generated picture.
Additional conditions:

The source code has to look like something Valentine's day themed (like a heart, or a poem or anything. Be creative)
All code and related assets need to fit into your answer.
You can use network connections, but you can only download this page (in case this question acquires multiple pages you can download them as well). You can use the StackApps API if you want to.
The "has to look like something Valentine's day themed" rule also applies to anything you try to use from this page (if using network connections).
No other external files are permitted.
You can use the standard library of your language, but no external packages are allowed.

Other restrictions:

None. This is a popularity contest.

Scoring:

Each visible vote (= upvotes minus downvotes) is worth 10 points
For every two upvote on a comment on your answer you get 1 points
Answer having the most score will be accepted on Valentine's day (14 Feb 2014)

**This contest is now closed, thanks for participating! ** You can still add answers if you'd like though

Tried to do this in Shakespeare and got bored.  I'd upvote anyone who did, though!

There's been a question on tex.SE that might be useful: Can we make a love heart with LaTeX?

C
What can be more romantic than syntax highlighting?
  *xx=       "De"
 "ar %"     "s:\n"
"Consta"   "nts ar"
"e red, " "variable"
"s are blue.\nIf lo"
"ve had a syntax, I"
 "'d highlight you"
  ".\n",n[9];main(
    ){printf(xx,
      gets(n))
        ;xx;
         }

Output:
$ echo Ilana | ./vanentine
Dear Ilana:
Constants are red, variables are blue.
If love had a syntax, I'd highlight you.

I laughed through the whole thing.

Why is this so darn funny?

Java 8, 500 lines of code
This is the longest entry that I had ever did here in codegolf. It is in the form of a java program constituted from the concatenation of the lyrics of 7 different songs that I composed just for this competition. Looking back in time, I am convicted that I am really crazy to create this thing just for this competition, and some verses are still repeating over and over with rhymes in my head.
Comments were very abused, so I could write everything in the program to be within verses, except for a short guitar solo in the end of the second song. There is no blobs of characters left hidden somewhere. In fact, I did not thought that to write music as poems with rhymes that could be compiled and run by a java compiler to do something not trivial was damn so hard, specially writing poems with terms like AffineTransform, BufferedImage, Graphics2D and newScheduledThreadPool.
The program itself is somewhat complex. It does show a screen with an animation of a rotating heart, some stars and a message for your beloved-one. All of that is done with linear algebra, primitives drawing, setting pixels, text drawing and sprites.
EDIT: Bugfix to reduce the font size to avoid text cuttings.
To run it:
java that_day <The name of your girlfriend/boyfriend>

If you omit your girlfriend/boyfriend name, it will show the usage and default to my name (Victor) instead. This is some sort of mark I left as a form of some personal signature.

Here is its source:
// ******************************************
// TRACK 1: THE GREAT LOVE IN THE JAVA ISLAND
// ******************************************

/* Do you ever */ import /* ?
|* If in the */ java /* island */.
/* There was a sign that once said:
*/ awt. /* what is this crazyness?*/*;

/* Or maybe instead,
|* Do you really */ import /* if in the */ java /* island */.
/* they really said */ awt.geom. /* instead? */*;

// Or even maybe,
/* Do you */ import /* if all that */ java.awt. /* had some */ image/*? */.*;
/* Do you */ import /* if that */ java /* has a */ .util.concurrent/*? */.*;
/* Do you */ import /* if that */ java /* has some */ .util.Random; // game?
/* Do you */ import /* if that */ static java /* has some */. lang/*uage or */. Math /* class? */.*;

// And then
/* We do */ import /* about all those */ javax // stuff
/* So, lets play in the school */ .swing /* like the old times, oh my honey?*/.*;

// In the school
/* I were in my */ class that_day{ //
/* And some */ Random stuff // the teacher were saying
=/* all that I wanted was a*/ new Random /* game to play*/(

); // But then you came!!!! */
/* And I felt the */ GreatLove /* in my */ heart,
/* you, were my */ star, /* you were all my */ life;

/* In that */ class
/* I saw my */ GreatLove // in your face
/* I was so happy that i wanted to */ extends /* a */ BufferedImage //!!!
{/* that */ GreatLove /* was */( int resting, /* and so */ int tense

/* i felt */){ super(//!!!
/* no */ resting, /* I was so */ tense,
/* I was sure that I wanted*/ 2 /*love you*/);

}}/* I would */ boolean your_heart(
/* a day */ long /*in*/ YourArms, long /*in*/ your_arms, long /*IN*/ YOUR_ARMS // OH YEAH!
){ /* I want to*/ return /*to*/ YourArms * /*, to return to */ YourArms +/* to return to*/ your_arms // OH YEAH!
/* to return to*/* your_arms </* to return to*/ YOUR_ARMS /*to return to*/* YOUR_ARMS;} // OH YEAH

// *******************************************
// TRACK 2: THE STRING GUIDING MY LIFE, PART I
// *******************************************

/* In the */ public//, you said you did not wanted me!
/* I frooze */ static /* and felt a */ void /* inside */
/* coz you were the */ main (String[] guiding_my_life

){ if (guiding_my_life /* was a string with such */ .length
/* I felt like I was */ == 0 // in that date.
){ /* That was the */ System. /* and i were */ out.
/* So i */ print//d this letter for you,
/* Remember, */( "usage is java that_day and-put-here-yours-love-name");

/* I was in a cinema's */} EventQueue.
/* I got your number, was going to */ invokeLater(()
-> /* But this day is a */ new //day
/* A day like */ that_day

/* Are you */ ((guiding_my_life/*? Even when its */. length == 0?
/* You are the */ new String[] /* of my life?
   Would I be a */ {"Victor"} : /* with my string */guiding_my_life)//?
[  0-0-0-0-0-0/*HHHHHH YEAH!*/]))

;} that_day
/* you are the */( String guiding_my_life) {
/* a */ int tense /* feeling with a level */ = 1000;
/* a */ long missed /* one with a number */ = 466,

/* I looked for your */ door /*. Now I know, its number is */ = 279,
/* but missed */ because /* I was looking for */ = 379,
/* I was so */ crazy /* that i looked even at the number */= 261, /* and */ number = 534;

/* And my */ heart /* was */ = /* that */ new GreatLove
/* Oh I was so */(tense, /* Oh I was so */ tense); // Oh yeah!

/* And then I am */ for/*ever*/ (int erested /* in you */ =000000000 ;// YEAH;
/* int*/erested </*in your in*/tense /*love*/;
/* int*/erested ++ // forever!

){ for/*ever */(int/*erested */ i_was =0-0-0-0-0-0//0-0-0-0-H-H-H-H-H-H YEAH
 ; i_was </*so*/ tense; i_was ++ // so tense, oh yeah!

){/* but, I knew that */ if (i_was +/* so */ missed >// by you
/* and you were too int*/erested
   & i_was -/* so */ missed </* and */ tense-
/* so int*/erested

   & (/*in*/ your_heart(
   i_was -/* looking at that */door,
/* int*/erested /*in you*/- because, /* i am */ crazy /* for you */)|

   your_heart
(  i_was -/* so */ tense +/*at your*/ door,
/* int*/erested /*in you*/- because, /* i am */ crazy )/* for you */|
/* int*/erested /*in your*/> number
|( i_was /**/> missed /* that much */ & i_was </* so */ tense
-  missed /* you too much */ & /*I am so int*/erested /*and*/> crazy)))

/* To your */ heart.
/* I would */ setRGB /* there */(
/* because */ i_was, /*int*/erested,

        // GUITAR SOLO:
        0XFFFF000___0 //0XF00_00X0__XF0F_0F0F0___00 F0X_F0F0X__FFF0X0__F000!!!
);      //F0000 0XF0_0XF0_0XF0 F0F0F0__F0F0F0__F0F0F000000000!
}}      // 0xFFFFFF000000000-0-0-0-00000000000000  X0_X0_X0_X000 YEAH!

/* You are my */ star=
// like you, no one will go so far
/* my */ new GreatLove( // you are

/* I was so */ tense, /* I was so */ (int)tense);
// OH YEAH!

// ****************************************
// TRACK 3: INTREPID INTUITIVE INTELLIGENCE
// ****************************************

   int[]repid /* I am, this is */ = /* my */ new int/*elligence*/[
/* Just */ 5 /* days I wait */];
/* This is my new */ int[]elligence
=/* my */ new int/*elligence*/

[  5 /* years */]; for // now
(  /* Is this */ int uitive // or nah?
=  0//r nah?
;  /*int*/uitive </*for*/ 5 //years
;  /*int*/ uitive
++ // Or nah?

){ /*int*/repid [/* or int*/uitive]
/* Is this */ = /* to */ (int)//elligence?
(  cos /* the */ (toRadians( 90+ // aliens came
// They came! they came!

/* From the */ 144 *
/* How this is int*/uitive)) /* how???

1- Oh, this */ * /* is so */ tense /
2- /* It is so */ -tense /( /*
3- /* It is so tense */
4- /* It is like */ 2 /* times so tense.*/)

); /* This is my int*/elligence[
/* My int*/uitive /* intelligence*/]=
(  int/*elligence*/)

(/* And the */ sin /* of the */( toRadians (90+ // aliens
/* is that they did not got my int*/uitive * // intelligence
1__44 /* times */)) /* that was so */* tense /
2  + /* the times this was so in*/tense /
   2 /* intense*/);}

// *******************************************
// TRACK 4: THE GRAPHICS OF THE LOVE IS A STAR
// *******************************************

/* The */ Graphics of_the_love /* is */ = /* to a */ star.
   getGraphics /**/();/**/ of_the_love /* and then */.setColor( // of the star
/* A */ Color /* that was something like */ .YELLOW
); /* The shape */ of_the_love /* is draw when you */.fillPolygon // of the star.

/* You have your reputation id, its the */( repid,
/* And you use it with much d*/elligence,
   5 /* times each day */);
/* You do discover */ life // again
= /* Its happy to see my */ new GreatLove // everyday

(/* I am so excited and a bit*/ tense,
/* I had that feeling so in*/tense);
/* The */ Graphics of_your_heart /* is*/ = /* to the */ life // of a star
.  getGraphics /**/();/**/ of_your_heart /* and then */.setColor( // of the sky
/* A */ Color /* that was something like */ .CYAN

); /* In the letters */ of_your_heart /* you */ .setFont
(/* And when you remember */ of_the_love /* you */.getFont().
/* In the happiness, please */ deriveFont /* everyday */(
/* You might do it only */ 1 /* time or even */, 67));
/* But do remember */ of_your_heart /* everyday */.

// ********************************************
// TRACK 5: THE STRING GUIDING MY LIFE, PART II
// ********************************************

/* Yesterday, I have */ drawString
 ( "Hey, " + /* I have to say that you are the string that was */ guiding_my_life
   + /* I say, plus I say, hey: */ ", I love you",
   20 /* times that I will say */,
   /* it was so */ tense /* but i will say it *// 2 -
   50 /* times that I will say */);

/* John */ JFrame /* is the name of my */ neighbour // in the next door
   = // him, I had no such friend as before
/* Some day I asked him for some */ new//s
/* Then */ JFrame /* said I got a letter and the sender was: */(

        "I love you, "+

/* it was nobody else but the string */ guiding_my_life);
/* I am so grateful to my */ neighbour /* coz he */ .setBounds(
/* I was */ 10 /* times excited and */, 10 // times happy
/* My emotion was at */, 500 /* percent */,
/* When I read the letter I falled in love */ 500 /* rounds */);

   MY_TRUE_LOVE /* was */ back_for_me
/* There is nothing */ = /* or even like this */
/* So I had a */ new /* chance, */ MY_TRUE_LOVE(); // finally came
/* And was my */ neighbour /* who */ .add(/* she */ back_for_me);
/* My */ neighbour. /* was great, he */ setVisible( /* me again
|| my */ true /* love was back to me! */);

// So I defined a new plan
/* and */ Executors /* it then */.
/* with a */ newScheduledThreadPool( /* For */ 1 /* time I had my love back again */).
/* and I */ scheduleWithFixedDelay(()
-> /* back in the cinema's */ EventQueue. /* I came
|| and then I */ invokeLater(() // her cellphone again!
-> /* She was finally */ back_for_me /*,
|| and the only difference was that her hair got a */ .repaint()),

/* I was feeling as a */ 0 /* before */,
/* Now I feel */ 50 // times more worth.
/* in each */, TimeUnit. /* of just some */ MILLISECONDS /* I'm love.*/);

/* And I won't forget my */ neighbour.
/* Just to */ setDefaultCloseOperation(
/* Now that I have a love and a great friend, we */ 3 /* really rocks!*/);}

// *************************************
// TRACK 6: HOMEWORK ABOUT A BORING BOAT
// *************************************

/* Last year in my */ class I_MET{ /* my */ GreatLove
   she; /* was so lovely that I knew: */ I_MET( /* my */ GreatLove
/* I was sure that she was really */ my_love
){ she /* is */ = /* to an angel, she is all */ my_love;}

/* Oh yeah, man she is */ double pretty, very_nice, /* and much */ talented,
/* She just should be my, beloved */ girl,friend;
/* But the teacher would */ void /* my weekend, he gave a homework:
/* to */ draw /* some stupid */(Graphics2D/*, of a boring */ boat) {

/* What I didn't knew, was that weekend would, */ AffineTransform my_life
=/*that */ new AffineTransform /* happened, really */()/*vernight. */;
/* The teacher said, the homework should be done in */ double//s
// And that was really when my chance came.

// I invited she, to join me in the homework
/* And she came to my house, because a */ boring //boat
= /* And */ she ./* measured the boat and */ getHeight
  (),vernight /* I managed */= she /* to */.getWidth ()/*n the same! */;

   my_life /* would change and then */ .rotate(
/* When she said that she had trouble in convert */ toRadians (
/* But in that stuff, I was really */ talented//!!!

),/* And because of that */ boring /* homework *//
/* We */ 2, /* got together O*/vernight /*, working on that boat. *//
/* The life of we */ 2 /* was about to */); AffineTransform // in that day
/* When she */ kissed_my_mouth // at midnight and ten.

/* For us both, that feelling was */ =/*lly*/ new
/* An */ AffineTransform ()/*n that night, that was for real */;
/* When she */ kissed_my_mouth/*, the feeling I can't */ .translate(-
   my_life. /* was */ transform/*ed*/( /* to a */ new // plane!

/* Working in a */Point2D. /*A homework in */Double(
/* She was really */ talented /*, but with */ >90 // percent done
/* I was so sad when she needed to go back to her home!

*/ & /* had i already said how she is */ talented/*?*/<
/* Had we kissed in */ 6 /* hours and */* 45 /* minutes of work*/?
/* O*/vernight /* working */: 0/*n the same boat.*/,
/* Man, had I already said how she is */ talented/*?*/<

/* Without her, could that be */ 180 /* times or worse of boring homework*/?
/* So */ boring: 0/*n that boat in an otherwise */), null // weekend
). /*But I had to */getX ()/*n*/ ,-my_life /*and*/. transform(
/* In a much better thing a */new Point2D /*homework to be done in */.Double//s

(/* Was she */ talented /* like something */ >180 /*percent*/?
/* O*/vernight : 0/*n the boat, I and my */, talented /* girl finished */ > 90 /* percent.
*/ & /* she is so*/ talented /* that in */ < 6 /*hours and */*45 /* minutes of */ ?boring /* homework
*/: 0/*n an otherwise */), null // weekend, we got a love!

)./* And now, we both */ getY//a new life!
()/*n that night */); my_life /* was */. preConcatenate//d
/* She */( kissed_my_mouth /* and she though me CorelDraw */);
/* However, she didn't knew about */ BufferedImage/*!!!

*/ i_knew =/*lly well right from the start */
/* that I would had a */ new AffineTransformOp /* in */( my_life,
/* and */ 2 /* that working to */).filter( /* out the boringness */
   she /* too did not got a */, null /* weekend */);

/* I had an */ AffineTransform on_my_life
/* She */ =/*lly had a */ new AffineTransform ()/*n*/ ,her_life
/* Oh, she really */ =/*lly had a */ new AffineTransform ()/*n*/ ;her_life
// OH YEAH!

/* I can't */.translate (/* how */ very_nice, /* and */ pretty /* she is.*/);
/* I got */ on_my_life /* a new */ .scale( /* of bliss. */
/* with a */ girl /* that kissed me, *// /* working a */ boring /* homework */,
/* got a girl*/friend /*O*//vernight )/* in a work about a boat. */;

   on_my_life /* I can't */.translate
/* How I became so live */((
/* from a */ boring -/* homework,
*/ i_knew. /* how to */getWidth(
)) /* We *// 2, /* working */( /*O*/vernight
-  // Until the night was high
   i_knew /* to */.getHeight
   ()//n the night when she came
)/ /* We gotta to be */ 2//gether
); //OH YEAH!

   on_my_life /* I */.preConcatenate(
/* And */ her_life // Would never be the same
); /* Looking the net for a */ boat. // page
/* To finally */ drawImage(

   i_knew, /* that with this girl */ on_my_life, /* I would never get a */ null // weekend!!!
); /* OH YEAH! */}}

/* And monday back in the */ class
   MY_TRUE_LOVE extends /* the */ JComponent
{  I_MET a_great_love
/* And */ =/*lly for her was this a */ new // love
   I_MET /* with her */( heart
); I_MET love // in her heart
/* And I */ =/*lly met a */ new // life!
   I_MET /* a new */ (life);

// *****************************************************
// TRACK 7: DOUBLE TROUBLE IN MY GIRL'S FATHER CARD SHOP
// *****************************************************

/* I was in */ double trouble, last_year, at_my_phone;
// The dad of my girl had a shop in his home.
/* He were open to the */ public // that day. But no customers came
/* Just a */ void // on the shop, that was all then.

/* He */ paintComponent/*s of some */(Graphics cards){
/* But */ trouble /* is */ = trouble + /* all that */ stuff.
/* The */ nextDouble /* trouble */ ()//ff the week
/* Was like */* 5 /* times as so big */-
   5 /* times *// 2. /* the dad of my girl. */

;  if (/* he was really bad to sell all that */ stuff.
/* The */ nextDouble /* trouble he had was */ ()/*nce a big */</**/ 1./
/* He had bad sells for more than */ 20 /* days */)
/* The truth is that */ trouble /* is */ = /* to */- trouble; // no matter when

/* As */ a_great_love /* my girl is so */. talented
/* To */ =lize (a_great_love/*,*/. talented // also I am!
/* But love */ + /* all that */ trouble // is really hard then
); /* And */ last_year /* to */ =lize(// the bills, that was a real pain

   last_year + 1 /* or maybe *//2. // months
); at_my_phone /* her dad called to */ =lize(// the bills ongoing
   at_my_phone /* he complained, and asked money to*/-/* give back in */ 7 /* days or maybe *// 10.);
// And that put me in trouble with my girlfriend!

/* But that */ Graphics2D CARDS // were really cool stuff!
=/*But that */(Graphics2D)cards;// were really-really cool stuff!
   int eresting // they were
=/* You could */ getWidth ()//f that
,  a_great_card_pile =/*lly was possible to make it */ getHeight /* very high*/

   ()/*n all those*/; CARDS. /* They */ setColor // very careful.
(/* and the */ new Color//s her father painted, all of them were very cool.
(/* But in the end, they only selled */ 15 /* or */* 17, // each day
/* But could produce more then */ 200 // everyday
/* And I counted */, 225 /* boxes of cards and paint abandoned in the store at that day. */));

/* Her dad in the */ CARDS/*, he did it */.fillRect
/* All that stuff was very */((int)eresting
-  (int)eresting, (int)eresting -/* very */ (int)eresting, /* really really */ (int)eresting,
// OH YEAH!

/* But my heart broke with such */ a_great_card_pile
);/* he weren't selling enough, and I had */ a_great_love /* to my */.girl
= /* I could not see a great */ (int)eresting // card shop end
; /* And I had */ a_great_love. /* to my girl*/friend
= /* And I decided that such */ a_great_card_pile /* should finally get an end! */;

/* My girl had */ a_great_love /* in */ .draw/*ing all those */(CARDS);
// OH YEAH!

   for (/* that situation, i did needed */int elligence
=/*from n*/0/*w on, I used my */; (int)elligence
<  2 /* sell everything*/ + /* handle all the bills and */ stuff.
   /* my */ nextInt//elligent move was to buy the card shop! */

(/*My girl was surprised, */ 5 /* times she said*/);
/* And she admired all that my int*/elligence /**/++
){ I_MET her_father /* he was */ =//lly surprised!

/* And after that I got to the shop a */ new // life. OH YEAH!
// But he imposed a condition: We had to merry, that was the reason

/* So in that church */ I_MET (/* my loving */star /*!!!!*/);
// OH YEAH!

/* And */ her_father. /* was my */ friend
= /* And to */ a_great_card_pile /* I had it to end. *//
/* For */ 6 /* dollars each card, */ + /* a few cents. */
/* With that */ stuff // done,
/* the */ .nextDouble /* trouble was gone! */
()/*n that day */* a_great_card_pile /* will never again be the reason to ring my phone! *//6;/*

*/ her_father /* was happy */.
/* His */ girl // was married!
=/*And how int*/eresting
/  6+ /* times we are selling all that */stuff.
   nextDouble /* tr*/()/*uble we had no more. */*

/* and look how */(int)eresting /
/* For just */ 6 /* bucks a card we selled */;

   her_father. /* was */ very_nice
=// The man was very nice.
// OH YEAH!

/* And */ stuff. /* was done. */
/* The */ nextDouble /* tr*/()/*uble was gone. */*(
/* And how int*/eresting-
   her_father /* was happy */.
/* coz his */ girl /* was married. */

); her_father/*s cards are */ .pretty
= /* he produces all that */stuff.
// And then I selled everything
// Until the last one!

/* The */ nextDouble /* tr*/()/*uble was gone. */*(
/* And to sell such */ a_great_card_pile // was a job done.

-  her_father /* were my old */. friend
); her_father /* were so much */ .talented
=/*And all those */ stuff // we happy worked together!

/* But indeed the */.nextDouble /* tr*/()/*uble then come! */*
/* For */ 360 /* days I could even not imagine! */;
   her_father /* used to */.draw( /* all those */ CARDS);}
// He did it pristine!
/* But now my */ love.girl /* was crying! */=
// Because her father was died.

/* And see how */ (int)eresting;
/* Is to feel */ love /* to a */ .friend
// But we do only perceive this
/* when it had come to the end */=
// But live goes on now.
   a_great_card_pile /* entirely new was set on now. */;

/* That was my */ love.
/* A girl very */ talented
/* She */ =lize//d her father
// artistic scent.

(/*My */ love /* girl is so */.talented
   +5 // times pround her father would now be then.
); /* And she */ love /* to */.draw(/* all those */ CARDS);}
/* She do it */ double // better
// of what did the old man.

/* Sometimes we rea*/lize(double /* times */ indeed){
/* That could her father has */ return//d
(( indeed </* in */0/*ur first kid*/)?
/* The boy is */ indeed //an artist.
+/* As was his grandpa */ 360 // months in the past.

:// When we do sell all those cards
/* I am very grateful */ indeed)
%// To that old man
// who once married his daughter to me.

/* I am */ 360 // times so grateful forever.
;} /* This is why I love so much his daughter
in his memory respect. */ }}

I especially liked the guitar solo part

@SztupY Thanks for the edit. Your old screenshot revealed a bug: the font used was too big and likely to cut the text. I reduced it, but had to put a new screenshot.

+1 for the amount of love you put into this for the thousands who will be receiving upside down text, hearts and stars.

@SimonT Both the text and the heart are rotating. Sometimes they will be upright, sometimes turned on sides, sometimes upside down, sometimes diagonally inclined, etc.

Gorgeous. I agree the guitar solo is eminently charming.

Befunge-93
Run as echo '[NAME]!' | ./befungee.py test (assuming the code below is in a file named 'test') for the output "Happy Valentine's day [NAME]!"
The top few lines are for reading in the name; if you remove them and just leave the heart it will simply say "Happy Valentine's day".
v
v      _ v            _v#                                 1<
>~:"!"-^ >10g1+:10p0p:^>" "37*2+2p"v"63*2+:"g"\2p2+2p" "10p^
         |        -" "<
v        <

>     92+:*91+9*v                  v:+19*2*5+<
   v*66*5+2*37*<>7+v            v1*<>*91+9*7v^29<
 v3<>*7+89*v   4  <>9v        v+<>*3^       >+9v^*<
v<>9^      v,_@^8*:+<>v      v<>9^             >1v^<
v*+       *>:^      ^<>v    v<>^                 +.^
>v^<                 ^<>v  v<>^                 v<>^
 >v^1<                ^1<**>4^                v4<>^
  >+v^9<                                    v*<>4^
    >9v^*7<                              v+3<>+^
      >1+v^*<                          v2<>*1^
         >:v^44<                    v8*<>7^
           >*1v^*<                v4<>*4^
              >+v^7*<          v9*<>7^
                >92v^4<      v2<>5*^
                   >+v^4<  v+<>3^
                     >5v^*:<>*^
                       >*v>2^
                         >^

Simply marvelous :) +1

Just when I thought there was nothing romantic about Befunge...

Extended Brainfuck
This is by no means the shortest code that does this. Actually not used any EBF feature except for the same as BF-RLE.
              +[->,10-]>>5+[-<6+>]                            <++.........>8+[-<8+
        >]<-.>7+[-<7->]<.-.6-.>9+[-<10+               >]<3-......>5+[-<6->]<.>7+[-<7->]<--
    .+.>7+[-<7+>]<.>9+[-<9->]<4-.>4+[-<5+>        ]<++........>4+[-<4+>]<-.>4+[-<4->]<+......>
   9+[-<10+>]<++..>9+[-<10->]<--......>7+[-<    8+>]<4+.>9+[-<9->]<-.>4+[-<5+>]<++.......>4+[-<
  4+>]< -.>4+[-<4->]<+.......>9+[-<10+>]<++..>9+[-<10->]<--.......>7+[-<8+>]<4+.>7+[-<8->]<4-...
  .....>6+[-<6+>]<.>5+[-<6+>]<3+.4-.>4+[-<4+>]<+.>9+[-<9->]<-.[-]<<[11+<]>[.>]10+.>4+[-<5+>]<++.
 .....>9+[-<10+>]<++.>9+[-<10->]<--........>9+[-<10+>]<++..>9+[-<10->]<--........>9+[-<10+>]<++.>
 10+[-<11->]<4-.>4+[-<5+>]<++......>9+[-<10+>]<++.>9+[-<10->]<--.>8+[-<8+>]<-.......>5+[-<6+>]<-.
 .>5+[-<6->]<+.......>8+[-<8->]<+.>9+[-<10+>]<++.>10+[-<11->]<4-.>4+[-<5+>]<++......>9+[-<10+>]<+
 +.>8+[-<9->]<5-.>4+[-<4->]<+.13+.....13-.>7+[-<8+>]<4+.>6+[-<7->]<3-.>4+[-<4->]LOVEME<+.13+.....
13-.>7+[-<8+>]<4+.>5+[-<6+>]<++.>9+[-<10->]<--.......>6+[-<7+>]<.>6+[-<6+>]<+.6-.5+.>9+[-<9->]<3+.
>8+[-<9+>]<5+.8-.>8+[-<9->]<3+.>8+[-<8+>]<+.13+.10-.>8+[-<8->]<4-.>9+[-<9+>]<3+.5-.8-.--.>4+[-<4+>
]<-.12-.3-.13+.>10+[-<10->]<4-.>4+[-<5+>]<++.....>4+[-<4+>]<-.>4+[-<4->]<+..8+.8-.....9+.9-..8+.8-
.....9+.9-..>7+[-<8+>]<4+.>7+[-<8->]<4-......>9+[-<10+>]<3-.>4+[-<4->]<--.>8+[-<9->]<3+.>9+[-<9+>]
<++.11-.7-.11+..>8+[-<9->]<4-.>9+[-<9+>]<+.3+.9-.7-.>8+[-<9->]<3+.>9+[-<9+>]<3+.12-.3-.>8+[-<9->]<
 3+.>8+[-<9+>]<-.6-.11+.11-.>4+[-<5+>]<3+.+.>9+[-<10->]<++.-.>4+[-<5->]<--.>4+[-<5+>]<++....>4+[-
 <4+>]<-.>4+[-<4->]<+.>7+[-<8+>]<4+.>7+[-<8->]<4-..13+.....13-.8+.+.9-.13+.....13-..>4+[-<4+>]<-.
  >4+[-<4->]<+.>7+[-<8+>]<4+.>9+[-<9->]<-.>4+[-<5+>]<++...>4+[-<4+>]<-.>4+[-<4->]<+...>7+[-<8+>]
  <4+.>7+[-<8->]<4-......>4+[-<4+>]<-.>8+[-<9+>]<5+..>5+[-<6->]<--.>7+[-<8->]<4-......>4+[-<4+>]
   <-.>4+[-<4->]<+...>7+[-<8+>]<4+.>9+[-<9->]<-.>4+[-<5+>]<++..>4+[-<4+>]<-.>4+[-<4->]<+.....>@
    7+[-<8+>]<4+.>7+[-<8->]<4-....>4+[-<4+>]<-.>8+[-<9+>]<5+....>5+[-<6->]<--.>7+[-<8->]<4-..
     ..>4+[-<4+>]<-.>4+[-<4->]<+.....>7+[-<8+>]<4+.>9+[-<9->]<-.>4+[-<5+>]<++.>4+[-<4+>]<-.>
      4+[-<4->]<+.......>7+[-<8+>]<4+.>7+[-<8->]<4-..>4+[-<4+>]<-.>8+[-<9+>]<5+......>5+[-<
       6->]<--.>7+[-<8->]<4-..>4+[-<4+>]<-.>4+[-<4->]<+.......>7+[-<8+>]<4+.>9+[-<9->]<-.>
        6+[-<6+>]<+.>7+[-<7+>]<-.>8+[-<8->]<+........>7+[-<8+>]<4+.>4+[-<5+>]<-.>7+[-<7->
          ]<-........>7+[-<7+>]<+.>8+[-<8->]<.>4+[-<4->]<+........>8+[-<8+>]<-.3-.>9+[
             -<9->]<-.>4+[-<5+>]<++..>8+[-<8+>]<.>7+[-<7->]<--..+...>7+[-<7+>]<..>
                5+[-<6+>]<-.>5+[-<6->]<++.>7+[-<7->]<--.+.>7+[-<7+>]<.>8+[-<8->
                   ]<+..>8+[-<8+>]<-.>7+[-<7->]<.-.6-.>9+[-<9+>]<4+.>5+[-<6-
                       >]<+..>7+[-<7->]<...-..6-.>5+[-<6->]<+.>4+[-<5+>]<
                             ++..........>9+[-<10+>]<++.>9+[-<10->]
                                 <--....>8+[-<8+>]<.>7+[-<8->]<
                                     -.7-....>9+[-<10+>]<++.
                                         >10+[-<11->
                                             ]<4-.

Usage:
bf ebf.bf < valentine.ebf > valentine.bf
echo "Code Golf" | bf valentine.bf

Output:
         _.-'~~~~~~`-._
        /      ||      \
       /       ||       \        Dear Code Golf
      |        ||        |
      | _______||_______ |
      |/ ----- \/ ----- \|       Join me and together
     /  (     )  (     )  \      we shall rule the galaxy!
    / \  ----- () -----  / \
   /   \      /||\      /   \
  /     \    /||||\    /     \
 /       \  /||||||\  /       \
/_        \o========o/        _\
  `--...__|`-._  _.-'|__...--'
          |    `'    |

Ascii art is not made by me but just picked up here.

rofl, the ascii is great for valentine's!

Perl
awfully looking heart 2:
eval's unable to compute a hint,
when I write perl, I think of you;
I think of you at every '. print'
just be with me, since I love you
'
   ;;@_=       split//,
 $@;$"=$^I,  $_=0.00.106.
117.115.116.032.0115.0105.
110.99.101.32.116.104.101.
32.118.105.111.108.101.116
 .115.32.97.114.0101.032.
  98.108.117.101.10."@_[
   14,11] @_[20,49] @_[
     46,1,6,11,2,4,33
       ,02,013], @{[
         shift]}$/"
          ,print

The poem thingy at the beginning is not fully used, but it is somewhat used, so cannot be removed;
Output:
$ perl valentine.pl \$NAME

just be with me, since I love you
just since the violets are blue
be my valentine, $NAME

Processing
Almost entirely based on this answer of mine. And the input part is taken from here with modifications.
public static final int px=25;
public static final int rectRad = 3;
PFont font;
public boolean[][] used;
public int[] heart = {

               65, 66, 67,                 72, 73, 74,
           84, 85, 86, 87, 88,         91, 92, 93, 94, 95,
      103,104,105,106,107,108,109,110,111,112,113,114,115,116,
  122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,
  142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,
  162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,
      183,184,185,186,187,188,189,190,191,192,193,194,195,196,
          204,205,206,207,208,209,210,211,212,213,214,215,
          224,225,226,227,228,229,230,231,232,233,234,235,
              245,246,247,248,249,250,251,252,253,254,
                  266,267,268,269,270,271,272,273,
                      287,288,289,290,291,292,
                          308,309,310,311,
                              329,330
                                 };

void setup( ) {                                  size(500,500);
background(255);                                 stroke(190+1);
strokeWeight(1.75); fill(0); font=createFont("Purisa",28,true);
textFont(font,28); frameRate(50); used = new boolean [width/px]
[height/px];} void keyReleased(){ if(key!=CODED){ switch(key) {
case BACKSPACE:name=name.substring(0,max(0,name.length() - 1));
break; case 0xA:                                 case RETURN:fd
=1==0;background                                 (0xFF); break;

                         case ESC: case DELETE:
                    break; default: name+=key; }}}
            boolean fd=true;String name=""; int c=0;
         void draw(){if(fd){background(255);text("Ple"
      +"ase enter a name:",35, 30); text(name,35,70);c=
   frameCount;return;}int i, j, df = width*height/px/px
 ,tf = (int)(500 * frameRate/1000);do{i=(int)random(
0, width/px);j=(int)random(0,height / px);} while
 (used[i][j] &&frameCount-c<= df);used[i][j] = true;
  if(frameCount-c > df+tf) {noLoop(); return;} else if(
     frameCount-c == df+tf) { fill(63+32); text("Dear "
         + name + ",", 10, 50); text("Happy Valentin"+
             "e's Day!", 80, 200);text("Love,\nAce",
                    10, 0xA * 43); return;} else if
                         (frameCount-c>=df+1) {

   return;} int R=(int)random(64,255-64); int G = (int)
 random(128,255); int B=(int)random(128,255); int alpha
=(int)random(55,85);int hash=j*width/px+i;if(java.util.
Arrays.binarySearch(
heart,hash)>=0) {R=
(int)random(128+64,
255);G=(int)random(
0,63);B=(int)random
(0,63); alpha=(int)random(70, 100);} fill(R,G,B,alpha);
 rect(i*px,j*px,px,px,rectRad,rectRad,rectRad,rectRad);
   }///////////////////////////////////////////////////

See the animation online here. (You may have to click on the canvas in order to be able to type input. The easiest way would be to click on the input prompt. Note that the code used in this online demo is slightly different due to differences between Processing (the program above) and Processing.js (the one used in the demo).)
Alternatively, here is one possible output, given the input "Sample Input":

Very nice output, but the code itself looks too much like, uh, code.

@ugoren I guess this should do the trick

Nice to see some Processing here!

Zozotez LISP
Zozotez is a LISP interpreter written in Extended BrainFuck.
          ;((((((((((((((((((((()))))))))))))))))))))
       ((\(even to know my programming language) ;(())
    (to (my programming language) 'Lisp);(((((())))))
(to (know |I love |) 'parentheses);(((((((())))))))
   (to (even you more than there are) c);(((((())))))
      (to (know |parentheses in my heart ()()()|)));()
         (~ w (c "(c w))) p " c 'Dear (r));((((()))))

How to run:
jitbf zozotez.bf

Paste in code with only one trailing newline. Then your *friends name. Output looks like this:
Dear Max Love
I love you more than there are
parentheses in my heart ()()()

Needless to say, this text displays a lot of love since who doesn't love lispy parentheses?

Java
           public       class
     Vale {public       static void
    main(         String      []args)
   {int a;         char       c,d,r,g;
   String            s        ="hi";//
    double                    x,y,z=0;
     System                .out.print          ("hi  ");
      String[            ]parts=s.split(      "///////");
        String          string="This is  -for-  ";double w;
         System        .out.print         ("")    ;int g1,a1;
           System     .out.println(        );       System.out
            .print(string);System.                  out.print("")
                    ;       System.                out.println
                            ("you and             me,two heart"
                                +" combine        together "
                                    +"always     till "
                                       +"end  of life"
                                           );}}

Result:
hi  This is  -for-  you and             me,two heart combine        together always     till end  of life

You need to print a greetings with a name supplied by parameters or input

Javascript
Working Demo
             var t = '<span class'+                              '="t">░</span>', r =
          '<span class="r">▓</span>',                          b = '<span class="b">█'+
        '</span>', w = '<span class="w">'+                '▒</span>', n = '<br>', heart = [ t,
       t, t, t, t, t, t, t, t, t, t, t, t, t,          t, n, t, t, t, b, b, b, t, t, t, b, b, b, t,
    t, t, n, t, t, b, r, r, r, b, t, b, r, r, r,       b, t, t, n, t,  b, r, w, w, r, r, b, r, r, r,
   r, r, b, t, n, t, b, r, w, r, r, r, r, r, r, r,   r, r, b, t, n, t, b, r, r, r, r, r, r, r, r, r, r,
  r, b, t, n, t, t, b, r, r, r, r, r, r, r, r, r, b, t, t, n, t, t, t, b, r, r, r, r, r, r, r, b, t, t,
  t, n, t, t, t, t, b, r, r, r, r, r, b, t, t, t, t, n, t, t, t, t, t, b, r, r, r, b, t, t, t, t, t, n,
    t, t, t, t, t, t, b, r, b, t, t, t, t, t, t, n, t, t, t, t, t, t, t, b, t, t, t, t, t, t, t, n, t,
     t, t, t, t, t, t, t, t, t, t, t, t, t, t, n ], space = function(n, c){ var a = [], i = 0; while
       ( i < n ){a.push(c);++i;} return a.join(''); }, card = function(name){ var e = name.length
            % 2, sp = (13 - name.length) / 2; return space(15, t) + n + space(sp, w) + name.
            toUpperCase() + ' I' + space(sp + (e?1:0), w) + n + heart.join('') + space(6, w)
             + 'YOU!' + space(6, w) + n + space(15, t) + n; }, out = document.getElementById
               ('card'), inp = document.getElementById('name'), plot = function(){out.
                    innerHTML =  card(inp.value)}; inp.addEventListener('change',
                           plot); out.style['font-family'] = 'monospace';
                               out.style['text-align']  = 'center';
                                   out.style['line-height'] =
                                      '12px'; out.style
                                        ['font-size']
                                          = '15px';
                                           plot
                                            ()
                                             ;

Python 9,459 bytes
Try it Online!

exec"""
        exec''           'print
      "".join(ma       p(chr,map(
    int,"32_32_32_   32_32_32_32_32
  _32_32_32_32_32_3 2_32_32_46_32_32_
 32_32_32_32_32_32_32_32_32_32_32_32_3
2_32_32_32_32_32_32_32_32_32_32_32_32_3
2_32_32_32_32_32_32_32_32_32_32_32_32_3
2_32_32_32_46_32_32_32_32_32_32_32_32_3
 2_32_32_32_32_32_13_10_32_32_32_32_32
  _42_32_32_32_46_32_32_32_32_32_32_3
   2_32_32_32_32_32_32_32_32_32_32_3
    2_46_32_32_32_32_32_32_32_32_32
      _32_32_32_32_32_46_32_32_32
        _32_32_32_32_32_46_32_3
          2_32_42_32_32_32_32
            _32_32_32_32_32
              _32_46_32_3
                2_32_32
                  _32
                   _
        32_32_           32_13_
      10_32_32_4       6_32_32_32
    _32_32_32_32_3   2_32_46_32_32_
  32_32_32_32_32_32 _32_32_32_32_32_3
 2_32_32_32_32_32_32_32_46_32_32_32_32
_32_32_32_46_32_32_32_32_32_32_32_32_32
_32_32_46_32_32_32_32_32_32_46_32_32_32
_32_32_32_32_32_46_32_32_32_32_32_13_10
 _32_32_32_32_32_32_32_32_111_32_32_32
  _32_32_32_32_32_32_32_32_32_32_32_3
   2_32_32_32_32_32_32_32_32_32_32_3
    2_32_32_32_46_32_32_32_32_32_32
      _32_32_32_32_32_32_32_32_32
        _32_32_32_32_46_32_32_3
          2_32_32_32_32_32_32
            _32_32_32_32_32
              _32_32_32_1
                3_10_32
                  _32
                   _
        32_32_           32_32_
      32_32_32_4       6_32_32_32
    _32_32_32_32_3   2_32_32_32_32_
  32_32_46_32_32_32 _32_32_32_32_32_3
 2_32_32_32_32_32_32_32_32_32_46_32_32
_32_32_32_32_32_32_32_32_32_46_32_32_32
_32_32_32_32_32_32_32_32_32_32_32_32_32
_32_32_32_32_13_10_32_32_32_32_32_32_32
 _32_32_32_48_32_32_32_32_32_46_32_32_
  32_32_32_32_32_32_32_32_32_32_32_32
   _32_32_32_32_32_32_32_32_32_32_32
    _32_32_32_32_32_32_32_32_32_32_
      32_32_32_32_32_32_32_32_32_
        32_32_32_32_32_32_32_32
          _32_32_32_32_32_32_
            32_13_10_32_32_
              32_32_32_32
                _32_32_
                  32_
                   3
        2_32_3           2_32_3
      2_32_32_32       _46_32_32_
    32_32_32_32_32   _32_32_32_46_3
  2_32_32_32_32_32_ 32_32_32_32_32_32
 _32_32_32_32_32_44_32_32_32_32_32_32_
32_32_32_32_32_32_32_32_32_32_44_32_32_
32_32_44_32_32_32_32_32_32_32_13_10_32_
46_32_32_32_32_32_32_32_32_32_32_92_32_
 32_32_32_32_32_32_32_32_32_46_32_32_3
  2_32_32_32_32_32_32_32_32_32_32_32_
   32_32_32_32_32_32_32_32_32_32_32_
    46_32_32_32_32_32_32_32_32_32_3
      2_32_32_32_32_32_32_32_32_3
        2_32_32_32_32_32_32_32_
          13_10_32_32_32_32_3
            2_32_46_32_32_3
              2_32_32_32_
                92_32_3
                  2_3
                   2
        _44_32           _32_32
      _32_32_32_       32_32_32_3
    2_32_32_32_32_   32_32_32_32_32
  _32_32_32_32_32_3 2_32_32_32_32_32_
 32_32_32_32_32_32_32_32_32_32_32_32_3
2_32_32_32_32_32_32_32_32_32_32_32_32_3
2_32_32_13_10_32_32_32_46_32_32_32_32_3
2_32_32_32_32_32_111_32_32_32_32_32_46_
 32_32_32_32_32_32_32_32_32_32_32_32_3
  2_32_32_32_32_46_32_32_32_32_32_32_
   32_32_32_32_32_32_32_32_32_32_32_
    32_32_46_32_32_32_32_32_32_32_3
      2_32_32_32_32_46_32_32_32_3
        2_13_10_32_32_32_32_32_
          46_32_32_32_32_32_3
            2_32_32_32_92_3
              2_32_32_32_
                32_32_3
                  2_3
                   2
        _32_32           _32_32
      _32_32_32_       32_32_44_3
    2_32_32_32_32_   32_32_32_32_32
  _32_32_32_46_32_3 2_32_32_32_32_32_
 32_32_32_32_32_32_32_32_32_46_32_32_3
2_32_32_32_32_32_32_32_32_13_10_32_32_3
2_32_32_32_32_32_32_32_32_32_32_32_32_3
5_92_35_35_92_35_32_32_32_32_32_32_46_3
 2_32_32_32_32_32_32_32_32_32_32_32_32
  _32_32_32_32_32_32_32_32_32_32_32_3
   2_32_32_32_32_32_46_32_32_32_32_3
    2_32_32_32_46_32_32_32_32_32_32
      _32_32_13_10_32_32_32_32_32
        _32_32_32_32_32_32_32_3
          2_35_32_32_35_79_35
            _35_92_35_35_35
              _32_32_32_3
                2_32_32
                  _32
                   _
        32_32_           32_32_
      32_32_32_3       2_32_46_32
    _32_32_32_32_3   2_32_32_32_32_
  32_32_32_32_32_32 _32_32_32_32_32_3
 2_32_32_46_32_32_32_32_32_32_32_32_32
_32_13_10_32_32_32_46_32_32_32_32_32_32
_32_32_35_42_35_32_32_35_92_35_35_92_35
_35_35_32_32_32_32_32_32_32_32_32_32_32
 _32_32_32_32_32_32_32_32_32_32_32_32_
  46_32_32_32_32_32_32_32_32_32_32_32
   _32_32_32_32_32_32_32_32_32_32_44
    _32_32_32_32_32_13_10_32_32_32_
      32_32_32_32_32_46_32_32_32_
        35_35_42_35_32_32_35_92
          _35_35_92_35_35_32_
            32_32_32_32_32_
              32_32_32_32
                _32_32_
                  32_
                   3
        2_32_4           6_32_3
      2_32_32_32       _32_32_32_
    32_32_32_32_32   _32_32_32_32_3
  2_32_32_32_46_32_ 32_32_32_32_32_32
 _32_32_32_32_32_32_13_10_32_32_32_32_
32_32_46_32_32_32_32_32_32_35_35_42_35_
32_32_35_111_35_35_92_35_32_32_32_32_32
_32_32_32_32_46_32_32_32_32_32_32_32_32
 _32_32_32_32_32_32_32_32_32_32_32_32_
  32_32_32_32_32_32_32_32_32_44_32_32
   _32_32_32_32_32_46_32_32_32_13_10
    _32_32_32_32_32_32_32_32_32_32_
      46_32_32_32_32_32_42_35_32_
        32_35_92_35_32_32_32_32
          _32_46_32_32_32_32_
            32_32_32_32_32_
              32_32_32_32
                _32_32_
                  32_
                   3
        2_32_3           2_32_4
      6_32_32_32       _32_32_32_
    32_32_32_32_32   _32_32_46_32_3
  2_32_32_32_32_32_ 32_32_32_44_32_13
 _10_32_32_32_32_32_32_32_32_32_32_32_
32_32_32_32_32_32_32_32_32_32_32_92_32_
32_32_32_32_32_32_32_32_32_46_32_32_32_
32_32_32_32_32_32_32_32_32_32_32_32_32_
 32_32_32_32_32_32_32_32_32_46_32_32_3
  2_32_32_32_32_32_32_32_32_32_32_32_
   32_32_13_10_95_95_95_95_94_47_92_
    95_95_95_94_45_45_95_95_95_95_4
      7_92_95_95_95_95_79_95_95_9
        5_95_95_95_95_95_95_95_
          95_95_95_95_47_92_4
            7_92_45_45_45_4
              7_92_95_95_
                95_95_9
                  5_9
                   5
        _95_95           _95_95
      _95_45_45_       45_95_95_9
    5_95_95_95_95_   95_95_95_95_95
  _95_95_32_13_10_3 2_32_32_47_92_94_
 32_32_32_94_32_32_94_32_32_32_32_94_3
2_32_32_32_32_32_32_32_32_32_32_32_32_3
2_32_32_32_32_94_94_32_94_32_32_39_92_3
2_94_32_32_32_32_32_32_32_32_32_32_94_3
 2_32_32_32_32_32_32_45_45_45_32_32_32
  _32_32_32_32_32_32_13_10_32_32_32_3
   2_32_32_32_32_32_45_45_32_32_32_3
    2_32_32_32_32_32_32_32_45_32_32
      _32_32_32_32_32_32_32_32_32
        _32_45_45_32_32_45_32_3
          2_32_32_32_32_45_32
            _32_32_32_32_32
              _32_32_32_4
                5_45_45
                  _32
                   _
        32_95_           95_32_
      32_32_32_3       2_32_32_94
    _32_32_32_32_3   2_13_10_32_32_
  32_45_45_32_32_95 _95_32_32_32_32_3
 2_32_32_32_32_32_32_32_32_32_32_32_32
_32_32_32_32_32_95_95_95_45_45_32_32_94
_32_32_94_32_32_32_32_32_32_32_32_32_32
_32_32_32_32_32_32_32_32_32_32_32_32_32
 _32_32_45_45_32_32_95_95_32_82_67_13_
  10_32_32_32_32_32_32_32_32_32_32_32
   _32_32_32_32_32_32_32_32_32_32_32
    _32_32_32_32_32_32_32_32_32_32_
      32_32_32_32_32_32_32_32_32_
        32_32_32_32_32_32_32_32
          _32_32_32_32_32_32_
            32_32_32_32_32_
              32_32_32_32
                _32_32_
                  32_
                   3
        2_32_3           2_32_3
      2_32_32_32       _32_13_10_
    32_32_32_32_68   _101_97_114_32
  _116_58_13_10_13_ 10_32_32_32_32_87
 _69_32_74_85_83_84_32_76_65_78_68_69_
68_32_65_32_80_82_79_66_69_32_79_78_32_
77_65_82_83_32_33_33_33_33_33_33_32_73_
83_78_39_84_32_84_72_65_84_32_69_88_67_
 73_84_73_78_71_32_63_33_63_33_63_33_3
  2_32_13_10_32_32_32_32_32_32_32_32_
   32_32_32_32_32_32_32_32_32_32_32_
    32_32_32_32_32_32_32_32_32_32_3
      2_32_32_32_32_32_32_32_32_3
        2_32_32_32_32_32_32_32_
          32_32_32_32_32_32_3
            2_32_32_32_32_3
              2_32_32_32_
                32_32_3
                  2_3
                   2
        _32_32           _32_32
      _32_32_32_       32_32_32_3
    2_13_10_32_32_   32_32_73_32_71
  _85_69_83_83_32_7 3_84_32_87_79_85_
 76_68_32_66_69_32_73_70_32_87_69_32_7
2_65_68_78_39_84_32_68_79_78_69_32_73_8
4_32_65_84_32_76_69_65_83_84_32_70_73_8
6_69_32_84_73_77_69_83_32_66_69_70_79_8
 2_69_32_32_32_32_32_13_10_32_32_32_32
  _32_32_32_32_32_32_32_32_32_32_32_3
   2_32_32_32_32_32_32_32_32_32_32_3
    2_32_32_32_32_32_32_32_32_32_32
      _32_32_32_32_32_32_32_32_32
        _32_32_32_32_32_32_32_3
          2_32_32_32_32_32_32
            _32_32_32_32_32
              _32_32_32_3
                2_32_32
                  _32
                   _
        32_32_           32_32_
      13_10_32_3       2_32_32_66
    _85_84_32_73_8   4_39_83_32_65_
  32_42_42_42_68_73 _70_70_69_82_69_7
 8_84_42_42_42_32_80_82_79_66_69_32_65
_78_68_32_87_69_32_68_73_68_32_73_84_32
_42_42_42_68_73_70_70_69_82_69_78_84_76
_89_42_42_42_32_33_33_33_49_49".split()
 ))).replace("t",raw_input("Name:"))''
  '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
   @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
    @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
      @@@@@@@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@@@@
          @@@@@@@@@@@@@@@@@@@
            @@@@@@@@@@@@@@@
              @@@@@@@@@@@
                @@@@@@@
                  @@@
                   @""".replace("@","").replace(" ","").replace("\n","").replace("raw_input","input").replace("_", " ").replace("input","raw_input")
Output(www.asciiartfarts.com/20120820.html).

                .                                            .

     *   .                  .              .        .   *          .

  .         .                     .       .           .      .        .

        o                             .                   .

         .              .                  .           .

          0     .

                 .          .                 ,                ,    ,

 .          \          .                         .

      .      \   ,

   .          o     .                 .                   .            .

     .         \                 ,             .                .

               #\##\#      .                              .        .

             #  #O##\###                .                        .

   .        #*#  #\##\###                       .                     ,

        .   ##*#  #\##\##               .                     .

      .      ##*#  #o##\#         .                             ,       .

          .     *#  #\#     .                    .             .          ,

                      \          .                         .

____^/\___^--____/\____O______________/\/\---/\___________---______________

   /\^   ^  ^    ^                  ^^ ^  '\ ^          ^       ---

         --           -            --  -      -         ---  __       ^

   --  __                      ___--  ^  ^                         --  __ RC

    Dear Code Golf:

    WE JUST LANDED A PROBE ON MARS !!!!!! ISN'T THAT EXCITING ?!?!?!

    I GUESS IT WOULD BE IF WE HADN'T DONE IT AT LEAST FIVE TIMES BEFORE

    BUT IT'S A ***DIFFERENT*** PROBE AND WE DID IT ***DIFFERENTLY*** !!!11

Not really Valentine's day themed ... But just under 10 kb :)