Code words in integer sequences

CJam, -20

COUNTErREVOLUTIONARIES],

Outputs the nth element in the sequence A010861.

COUNTE                      e# push values of six preinitialized variables
      r                     e# read a token of input
       REVOLUTIONARIES      e# push values of 15 other preinitialized variables
                      ]     e# wrap whole stack in array
                       ,    e# get length

Removing a character from the word results in a completely different sequence A010860. There is a quite interesting relationship between the two sequences: at every index n, A010860(n) is coprime to A010861(n)! There must be some deep mathematical reason behind this.

Try it here.


CJam, -5

limpet;

A010051: prints 0 for composite numbers and 1 for primes.

It took me forever to find something that scored a few points and would break at the removal of any letter. Removing anything except m throws an error, and removing m turns the program into the identity function.

li  e# Read input and convert to integer.
mp  e# Check for primality.
et  e# Get current datetime as a list.
;   e# Discard the datetime again.

Try it online.


05AB1E, -4 -11

Code, prints A010869 (constant 30):

ASYNcHRonouSlyI)g

Previous code:

DoGS

Explanation:

D     # Duplicate top of the stack
 o    # Pop a, push 2**a
  G   # For N in range(1, 2**a):
   S  # Push all chars seperate from the top of the stack

Prints the A010879 sequence.