Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the most common filename extension of a Forth source code file?

I have seen people save Forth source code files with the extensions .4th, .fth, .frt and .f. Which is the most common filename extension of Forth source code files?

like image 652
Aadit M Shah Avatar asked Aug 15 '13 05:08

Aadit M Shah


2 Answers

Inspired by Lars Brinkhoff's answer, I ran some queries myself on GitHub to find out how the various extension names are used between various languages (not just Forth). For each extension in the list below, only the top 3 languages with the highest number of results are shown:

  • .fs
    • F# - 148303
    • Forth - 83217
    • GLSL - 61806
  • .fth
    • Forth - 10119
  • .f
    • Fortran - 2192549
    • Forth - 7725
    • Filebench WML - 5946
  • .4th
    • Forth - 5668
    • Shell - 1
  • .frt
    • Forth - 1950
  • .fr
    • Text - 92789
    • Frege - 25118
    • Forth - 1848
  • .forth
    • Forth - 344
  • .for
    • Fortran - 44077
    • Formatted - 7894
    • Forth - 27
  • .ft
    • Perl - 26
    • XML - 21
    • Forth - 16

The results above were obtained on 13 May 2021 at 15:30 UTC.

Note: GitHub sometimes detects the wrong language for source code files. The above queries attempt to reduce the impact of such errors on the results above but they aren't perfect.

Conclusions:

  • The most popular extension for Forth source code appears to be .fs but the extension .fs is most often used for F#. In fact there are about twice as many F# source code files with this extension as there are for Forth.
  • The most popular extension for Forth source code that does not appear to be used for any other language is .fth.
  • The extensions .4th, .frt, and .forth also do not appear to be used for any other language, however, these extensions are less popular than .fth.
like image 68
Susam Pal Avatar answered Sep 18 '22 10:09

Susam Pal


I searched for various file extension on GitHub (plus "dup drop swap"), and this was the result:

  1. .fs 4783 hits
  2. .fth 1144
  3. .4th 509
  4. .f 398
  5. .fr 143
  6. .4 55
  7. .frt 46
  8. .scr 30
  9. .forth 20
  10. .ft 11
  11. .fb 4
  12. .blk 2
  13. .seq 1
  14. .ans 1
  15. .for 1
  16. .fo 0

If nothing else, this shows there are many file extensions to chose from.

like image 31
Lars Brinkhoff Avatar answered Sep 20 '22 10:09

Lars Brinkhoff