Skip to content

Explore the 64 ancient hexagrams as a data structure of nested collections

Notifications You must be signed in to change notification settings

ajtran303/hexagrams

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

hexagrams.rb

Explore the 64 Hexagrams as a data structure of nested collections.

Setup

git clone [email protected]:ajtran303/hexagrams.git
cd hexagrams
bundle install

# try the program
ruby runner.rb -r

Usage

  usage: $ ruby runner.rb [-h|-r|-a|NUMBER]
      -h        Display this message
      -r        Display random hexagram
      -a        Display all hexagrams
      NUMBER    Display numbered hexagram (1-64)

Screenshots

Screenshot of Hexagrams 19 and 20, named Approach and Contemplation.

Screenshot of Hexagram 2, named Receptive Earth.

awesome_print gem

Pretty print your Ruby objects with style
-- in full color and with proper indentation

I highly recommend checking out the awesome_print documentation!

I use it to wrap my head around giant data structures!

What are hexagrams?

A hexagram is a symbol that represents life experiences. They have many qualities, such as numbers, names, and trigrams.

A trigram is a symbol that corresponds to an aspect of nature. Two trigrams combine to make one hexagram.

Hexagrams are determined and generated (usually drawn) by manipulating numbers. There is usually an aspect of "randomness" to the numbers chosen.

There are 64 hexagrams and they come from the I-Ching, an ancient Chinese book ("The Book of Change[s]").

If you want to read more about the I-Ching, here is a good article to start with.

There are many translations of the I-Ching available online if you want to check those out (nudge nudge).

There are many ways to consult and interpret the Book of Changes -- it is common to consult the I-Ching as an oracle for divining the future.

About

Explore the 64 ancient hexagrams as a data structure of nested collections

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages