Skip to content

Instantly share code, notes, and snippets.

ohce is a console application that echoes the reverse of what you input through the console.

Even though it seems a silly application, ohce knows a thing or two.

  1. When you start ohce, it greets you differently depending on the current time, but only in Spanish:
    • Between 20 and 6 hours, ohce will greet you saying: ¡Buenas noches < your name >!
    • Between 6 and 12 hours, ohce will greet you saying: ¡Buenos días < your name >!
    • Between 12 and 20 hours, ohce will greet you saying: ¡Buenas tardes < your name >!
  2. When you introduce a palindrome, ohce likes it and after reverse-echoing it, it adds ¡Bonita palabra!
  3. ohce knows when to stop, you just have to write Stop! and it'll answer Adios < your name > and end.
@michaelfeathers
michaelfeathers / Server.java
Last active May 29, 2024 15:25
Scratch Refactoring Exercise
package server;
import java.io.BufferedReader;
import java.io.FileReader;
import java.util.Date;
import java.util.Properties;
import java.util.Vector;
import javax.mail.*;
import javax.mail.internet.*;