-- |
-- Module      :  DobutokO.Poetry.Auxiliary
-- Copyright   :  (c) OleksandrZhabenko 2020
-- License     :  MIT
-- Stability   :  Experimental
-- Maintainer  :  olexandr543@yahoo.com
--
-- Helps to order the 7 or less Ukrainian words (or their concatenations) 
-- to obtain (to some extent) suitable for poetry or music text.

module DobutokO.Poetry.Auxiliary (
  -- * Help functions
  fourFrom5
  , lastFrom5
  , twoFrom3
  , lastFrom3
) where

twoFrom3 :: (a,b,c) -> (a,b)
twoFrom3 (x,y,_) = (x,y)

lastFrom3 :: (a,b,c) -> c
lastFrom3 (_,_,z) = z

fourFrom5 :: (a,b,b,b,c) -> (a,b,b,b)
fourFrom5 (x,y0,y1,y2,_) = (x,y0,y1,y2)

lastFrom5 :: (a,b,b,b,c) -> c
lastFrom5 (_,_,_,_,z) = z