Ubuntu下支持哪些编程语言(续篇)?

2026-05-25 11:530阅读0评论SEO资讯
  • 内容介绍
  • 文章标签
  • 相关推荐

本文共计2235个文字,预计阅读时间需要9分钟。

Ubuntu下支持哪些编程语言(续篇)?

在上篇随笔中,介绍了四种编程语言。这次再介绍四种:Fortran、Lua、Lisp 和 Logo。

Ubuntu下支持哪些编程语言(续篇)?

Fortran:Fortran 语言在 2010 年 6 月编程语言排行榜中排名第三十一。下面是 GregorianTest.for 程序:

fortran! GregorianTest.forprogram GregorianTest implicit none integer :: year, month, day logical :: is_leap_year

year=2020 month=2 day=29

is_leap_year=.false.

if (mod(year, 4)==0) then if (mod(year, 100) /=0 .or. mod(year, 400)==0) then is_leap_year=.true. end if end if

if (is_leap_year) then print *, 'This is a leap year.' else print *, 'This is not a leap year.' end ifend program GregorianTest

在上一篇随笔中介绍了四种编程语言。

阅读全文

本文共计2235个文字,预计阅读时间需要9分钟。

Ubuntu下支持哪些编程语言(续篇)?

在上篇随笔中,介绍了四种编程语言。这次再介绍四种:Fortran、Lua、Lisp 和 Logo。

Ubuntu下支持哪些编程语言(续篇)?

Fortran:Fortran 语言在 2010 年 6 月编程语言排行榜中排名第三十一。下面是 GregorianTest.for 程序:

fortran! GregorianTest.forprogram GregorianTest implicit none integer :: year, month, day logical :: is_leap_year

year=2020 month=2 day=29

is_leap_year=.false.

if (mod(year, 4)==0) then if (mod(year, 100) /=0 .or. mod(year, 400)==0) then is_leap_year=.true. end if end if

if (is_leap_year) then print *, 'This is a leap year.' else print *, 'This is not a leap year.' end ifend program GregorianTest

在上一篇随笔中介绍了四种编程语言。

阅读全文