lib/music/note.rb
def pitch
      result = chromatic_idx + (octave.to_i * CHROMATIC_SCALE.size)
      result %= CHROMATIC_SCALE.size if octave.nil?
      result
    end
##
# Internal integer representation on the note.
#
# @return [Integer]
#
Internal integer representation on the note.
Internal integer representation on the note .
def pitch
      result = chromatic_idx + (octave.to_i * CHROMATIC_SCALE.size)
      result %= CHROMATIC_SCALE.size if octave.nil?
      result
    end
def pitch result = chromatic_idx + ( octave . to_i * CHROMATIC_SCALE . size ) result %= CHROMATIC_SCALE . size if octave . nil? result end
Internal integer representation on the note.
Internal integer representation on the note .
None
Integer