转换到和从印度教日历 [英] Converting to and from Hindu calendar

查看:546
本文介绍了转换到和从印度教日历的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何将 unix 时间转换为印度教日历 > c>,,,Perl c>或 Python Java ?我知道我可以转换为希伯来语 Jewish 。但印度教不是一个选项。

How can I convert unix time to Hindu calendar­Wikipedia time and the other way round in php, Perl or Python or Java? I know I can convert to Hebrew and Jewish. But Hindu is not an option.

更具体地说,我在谈论印度教农历。以下网站正在工作,完全符合我的要求: http://web.meson.org/calendars/ 。例如,它将 28-1-2012 (Gregorian)转换为 5-11-2068 Lun。)。如何完成同样的任务?

To be more specific, I'm talking about the Hindu lunar calendar. The following website is working and does exactly what I want: http://web.meson.org/calendars/. For example, it 'translates' 28-1-2012 (Gregorian) to 5-11-2068 (Hind. Lun.). How can I accomplish the same task? And if there are absolutely no scrips out there, how can I write it myself?

推荐答案

纸张:印度日历计算

在附录中提供Common Lisp代码。

Paper: Indian Calendrical Calculations
Provides Common Lisp code in the appendix.

虽然根据本文可以编写Python(或其他语言)解决方案,但作者枚举印度日历规则相当不错,所以如果你愿意考虑采用提供Common Lisp代码。

While a Python (or other language) solution could be written according to the paper, the authors enumerate the Indian calendar rules pretty well, so it's a pretty solid paper if you're willing to consider taking the provided Common Lisp code.

这篇关于转换到和从印度教日历的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆