Last active
April 7, 2021 04:14
-
-
Save davit312/4d406da3f7a84998509b6e454607471a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getSign(year){ | |
let devider = 12 | |
let signNames = [ | |
'կապիկ', 'աքլոր', 'շուն', 'խոզ', | |
'մուկ', 'ցուլ', 'վագր', 'կատու', | |
'վիշապ', 'օձ', 'ձի', 'այծ', | |
] | |
return signNames[year % devider] | |
} | |
function getZodiac(month, day){ | |
let devider = 4 | |
let zodiacNames = [ | |
'այծեղջյուր', 'ջրհոս', 'ձկներ', 'խոյ', | |
'ցուլ', 'երկվորյակներ', 'խեցգետին', 'առյուծ', | |
'կույս', 'կշեռք', 'կարիճ', 'աղեղնավոր', | |
] | |
let elementNames = ['հող', 'օդ', 'ջուր', 'կրակ',] | |
month -= 1 | |
/* նշանի շտկում | |
if(day > 22){ | |
month += 1 | |
if(month == 12){ | |
month = 0 | |
} | |
} | |
*/ | |
return { | |
zodiac: zodiacNames[month], | |
element: elementNames[month % devider] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment