Rosetta Code/Rank languages by popularity: Difference between revisions

m (→‎Raku: Using the API: New URL for relocated site)
(14 intermediate revisions by 8 users not shown)
Line 1,176:
 
=={{header|C sharp|C#}}==
Sorting only programming languages.<br>
Note that this does not distinguish between tasks and non-task categories, so the counts can exceed the total number of tasks.<br>
<syntaxhighlight lang="csharp">using System;
Note this may need to set the Security Protocol type to Tls12 - see the section Problem running the C# entry in [[Talk:Rosetta_Code/Count_examples]]
<syntaxhighlight lang="csharp">
using System;
using System.Collections;
using System.Collections.Generic;
Line 1,188 ⟶ 1,191:
static void Main(string[] args)
{
string get1get2 = new WebClient().DownloadString("http://www.rosettacode.org/w/apiindex.php?action=query&list=categorymembers&cmtitle=Category:Programming_Languages&cmlimit=500&format=json");
string get2 = new WebClient().DownloadString( +"http://www.rosettacode.org/w/index.php?title=Special:Categories&limit=5000");
);
 
ArrayList langs = new ArrayList();
Dictionary<string, int> qtdmbr = new Dictionary<string, int>();
 
string cmcontinue = "";
MatchCollection match1 = new Regex("\"title\":\"Category:(.+?)\"").Matches(get1);
MatchCollection match2 = new Regex("title=\"Category:(.+?)\">.+?</a>[^(]*\\((\\d+) members\\)").Matches(get2);
 
do
foreach (Match lang in match1) langs.Add(lang.Groups[1].Value);
{
string get1 = new WebClient().DownloadString("http://www.rosettacode.org/w/api.php?"
+"action=query&list=categorymembers"
+"&cmtitle=Category:Programming_Languages"
+"&cmlimit=500&format=json"
+cmcontinue
);
cmcontinue = "";
MatchCollection languageMatch = new Regex("\"title\":\"Category:(.+?)\"").Matches(get1);
MatchCollection cmcontinueMatch = new Regex("cmcontinue\":\"([a-z0-9A-Z|]*)\"").Matches(get1);
foreach (Match lang in languageMatch) langs.Add(lang.Groups[1].Value);
foreach (Match more in cmcontinueMatch) cmcontinue = "&cmcontinue=" + more.Groups[1].Value;
}
while( cmcontinue != "" );
 
MatchCollection match2 =
new Regex("title=\"Category:(.+?)\">.+?</a>[^(]*\\(([\\d,.]+) members\\)").Matches(get2);
 
foreach (Match match in match2)
Line 1,203 ⟶ 1,223:
if (langs.Contains(match.Groups[1].Value))
{
qtdmbr.Add(match.Groups[1].Value, Int32.Parse(match.Groups[2].Value));
.Replace(",",string.Empty)
.Replace(".",string.Empty)));
}
}
 
string[] test =
string[] test = qtdmbr.OrderByDescending(x => x.Value).Select(x => String.Format("{0,3} - {1}", x.Value, x.Key)).ToArray();
qtdmbr.OrderByDescending(x => x.Value).Select(x => String.Format("{0,4} {1}", x.Value, x.Key)).ToArray();
 
int count = 1;
Line 1,213 ⟶ 1,236:
foreach (string i in test)
{
Console.WriteLine("{0,34}.: {1}", count, i);
count++;
}
}
}
}</syntaxhighlight>
</syntaxhighlight>
{{out|Output (as of May 30, 2010)}}
{{out|Output (as of September 11, 2023)}}
1. 397 - Tcl
<pre>
2. 368 - Python
3. 3501: -1660 RubyPhix
4. 3332: -1653 JWren
5. 3323: -1617 CJulia
6. 3224: -1598 HaskellRaku
7. 3225: -1577 OCamlNim
8. 3026: -1548 PerlGo
7: 1537 Perl
9. 290 - Common Lisp
8: 1487 Python
10. 289 - AutoHotkey
9: 1376 J
10: 1287 C
. . .
</pre>
 
===Object-oriented solution===
<syntaxhighlight lang="csharp">using System;
Line 2,603 ⟶ 2,630:
 
=={{header|Julia}}==
Uses the API for the language list and page scraping for the example counts for each language.
<syntaxhighlight lang="julia">using HTTP
<syntaxhighlight lang="julia">""" Rosetta code task rosettacode.org/wiki/Rosetta_Code/Rank_languages_by_popularity """
 
using Dates
try
using DataFrames
response = HTTP.request("GET", "http://rosettacode.org/mw/index.php?title=Special:Categories&limit=5000")
using HTTP
langcount = Dict{String, Int}()
using JSON3
for mat in eachmatch(r"<li><a href[^\>]+>([^\<]+)</a>[^1-9]+(\d+)[^\w]+member.?.?</li>", String(response.body))
 
if match(r"^Programming", mat.captures[1]) == nothing
""" Get listing of all tasks and draft tasks with authors and dates created, with the counts as popularity """
langcount[mat.captures[1]] = parse(Int, mat.captures[2])
function rosetta_code_language_example_counts(verbose = false)
URL = "https://rosettacode.org/w/api.php?"
LANGPARAMS = ["action" => "query", "format" => "json", "formatversion" => "2", "generator" => "categorymembers",
"gcmtitle" => "Category:Programming_Languages", "gcmlimit" => "500", "rawcontinue" => "", "prop" => "title"]
queryparams = copy(LANGPARAMS)
df = empty!(DataFrame([[""], [0]], ["ProgrammingLanguage", "ExampleCount"]))
 
while true # get all the languages listed, with curid, eg rosettacode.org/w/index.php?curid=196 for C
resp = HTTP.get(URL * join(map(p -> p[1] * (p[2] == "" ? "" : ("=" * p[2])), queryparams), "&"))
json = JSON3.read(String(resp.body))
pages = json.query.pages
reg = r"The following \d+ pages are in this category, out of ([\d\,]+) total"
for p in pages
lang = replace(p.title, "Category:" => "")
langpage = String(HTTP.get("https://rosettacode.org/w/index.php?curid=" * string(p.pageid)).body)
if !((m = match(reg, langpage)) isa Nothing)
push!(df, [lang, parse(Int, replace(m.captures[1], "," => ""))])
verbose && println("Language: $lang, count: ", m.captures[1])
end
end
!haskey(json, "query-continue") && break # break if no more pages, else continue to next pages
queryparams = vcat(LANGPARAMS, "gcmcontinue" => json["query-continue"]["categorymembers"]["gcmcontinue"])
end
 
langs = sort(collect(keys(langcount)), lt=(x, y)->langcount[x]<langcount[y], rev=true)
return sort!(df, :ExampleCount, rev = true)
for (i, lang) in enumerate(langs)
println("Language $lang can be ranked #$i at $(langcount[lang]).")
end
catch y
println("HTTP request failed: $y.")
exit()
end
</syntaxhighlight>{{out}
<pre>
Language Phix can be ranked #1 at 995.
Language Racket can be ranked #2 at 989.
Language Perl can be ranked #3 at 969.
Language Julia can be ranked #4 at 968.
Language C can be ranked #5 at 944.
Language Tcl can be ranked #6 at 930.
Language Zkl can be ranked #7 at 919.
Language J can be ranked #8 at 905.
Language Java can be ranked #9 at 900.
Language REXX can be ranked #10 at 892.
Language D can be ranked #11 at 874.
Language Ruby can be ranked #12 at 869.
Language Haskell can be ranked #13 at 853.
Language Scala can be ranked #14 at 792.
Language Sidef can be ranked #15 at 788.
Language PicoLisp can be ranked #16 at 775.
Language C sharp can be ranked #17 at 763.
Language Mathematica can be ranked #18 at 743.
Language C++ can be ranked #19 at 738.
Language Common Lisp can be ranked #20 at 667.
Language Ada can be ranked #21 at 656.
Language AutoHotkey can be ranked #22 at 628.
Language JavaScript can be ranked #23 at 619.
Language Lua can be ranked #24 at 618.
Language WikiStubs can be ranked #25 at 614.
...
</pre>
 
println("Top 20 Programming Languages on Rosetta Code by Number of Examples, As of: ", now())
===Julia: Using web scraping===
println(rosetta_code_language_example_counts()[begin:begin+19, :])
{{trans|Python}}
 
<syntaxhighlight lang="julia">
</syntaxhighlight>{{out}}
using HTTP, Dates
response = HTTP.request("GET", "http://rosettacode.org/wiki/Category:Programming_Languages")
languages = Set(m.captures[1] for m in eachmatch(r"title=\"Category:(.*?)\">",String(response.body)))
response = HTTP.request("GET", "http://rosettacode.org/mw/index.php?title=Special:Categories&limit=5000")
response = replace(String(response.body),"," => "")
reg = r"<li><a[^>]+>([^<]+)</a>[^(]*[\(](\d+) member[s]?[)]</li>"
ms = eachmatch(reg,response)
members = [[1,parse(Int,m.captures[2]),m.captures[1]] for m in ms]
filter!(x -> x[3] in languages, members)
sort!(members, by = x -> (-x[2],x[3]))
for i in 2:length(members)
if members[i-1][2] == members[i][2]
members[i][1] = members[i-1][1]
else
members[i][1] = i
end
end
println("Sample output on ", Dates.day(now()), " ", Dates.monthname(now()), " ", Dates.year(now()), ":\n")
for (rank,entries,name) in members[1:10]
println("Rank: ", lpad(rank,4), lpad(" ($entries entries) ",16), name)
end
</syntaxhighlight>
{{out}}
<pre>
Top 20 Programming Languages on Rosetta Code by Number of Examples, As of: 2022-09-05T14:59:56.316
Sample output on 22 July 2019:
20×2 DataFrame
 
Row │ ProgrammingLanguage ExampleCount
Rank: 1 (1154 entries) Go
│ String Int64
Rank: 2 (1089 entries) Perl 6
─────┼───────────────────────────────────
Rank: 3 (1070 entries) Julia
1 │ Wren 1569
Rank: 4 (1066 entries) Python
2 │ Phix 1569
Rank: 5 (1062 entries) Phix
3 │ Julia 1537
Rank: 6 (1045 entries) Kotlin
4 │ Raku 1517
Rank: 7 (1026 entries) Perl
5 │ Go 1496
Rank: 8 (991 entries) Racket
6 │ Perl 1460
Rank: 9 (952 entries) C
7 │ Python 1404
Rank: 10 (945 entries) J
8 │ Nim 1402
9 │ J 1275
10 │ C 1210
11 │ Mathematica 1178
12 │ REXX 1149
13 │ Haskell 1139
14 │ Java 1136
15 │ Kotlin 1133
16 │ C++ 1120
17 │ Ruby 1103
18 │ Racket 1089
19 │ FreeBASIC 1069
20 │ Zkl 1011
</pre>
 
Line 3,137 ⟶ 3,143:
 
=={{header|Nim}}==
<syntaxhighlight lang="nim">import std/[Algorithm, httpclient, json, re, strformat, strutils, algorithm]
 
const
LangSite = "http://www.rosettacode.org/mww/api.php?action=query&list=categorymembers&cmtitle=Category:Programming_Languages&cmlimit=500&format=json"
CatSite = "http://www.rosettacode.org/mww/index.php?title=Special:Categories&limit=5000"
let regex = re"title=""Category:(.*?)"">.+?</a>.*\((.*) members\)"
 
Line 3,152 ⟶ 3,158:
proc add(langs: var seq[string]; fromJson: JsonNode) =
for entry in fromJson{"query", "categorymembers"}:
langs.addlet title = entry["title"].getStr.split("Category:")[1]
if title.startsWith("Category:"):
langs.add title[9..^1]
 
var client = newHttpClient()
Line 3,179 ⟶ 3,187:
</syntaxhighlight>
Output:
<pre> 1 13441626 - GoPhix
2 13291620 - PhixWren
3 13231587 - Julia
4 13031574 - Raku
5 12521533 - PerlGo
6 12241520 - PythonPerl
7 11201466 - KotlinPython
8 11091430 - CNim
9 10951348 - JavaJ
10 10661264 - WrenC
11 10641198 - REXXRuby
12 10611185 - RacketMathematica
13 10211164 - JJava
14 10121160 - ZklHaskell
15 10071155 - RubyC++
16 10011153 - C++REXX
17 9931136 - NimKotlin
18 9891131 - HaskellFreeBASIC
19 9661100 - DRacket
20 9611027 - TclJq
21 9151014 - Scala11l
22 8771012 - C sharpZkl
23 8701004 - Sidef
24 852997 - Factor
25 830987 - PicoLispD
26 792980 - LuaTcl
27 780938 - Ada
28 778926 - RustC sharp
29 761923 - MathematicaScala
30 721906 - CommonALGOL Lisp68
31 896 - Rust
32 893 - Lua
33 849 - PicoLisp
34 843 - F Sharp
35 824 - AutoHotkey
36 818 - Ring
37 793 - Delphi
38 785 - JavaScript
39 778 - Arturo
40 776 - XPL0
...</pre>
 
Line 3,655 ⟶ 3,673:
</pre>
Note: If MC++ and µC++ are the same, they should/could be added together to get 501 languages.
 
=={{header|PascalABC.NET}}==
Using web scraping. May 2024.
<syntaxhighlight lang="delphi">
uses System.Net;
 
begin
ServicePointManager.SecurityProtocol := SecurityProtocolType(3072);
var wc := new WebClient;
wc.Encoding := Encoding.UTF8;
var s := wc.DownloadString('https://rosettacode.org/wiki/Special:Categories?limit=5000');
s.Matches('([^><]+)</a>.+\(([\d,]+) member')
.Select(x -> KV(x.Groups[1].Value,x.Groups[2].Value.Replace(',','').ToInteger))
.Where(x -> not x.Key.StartsWith('Pages'))
.OrderByDescending(pair -> pair.Value).Numerate.Take(10)
.PrintLines(x -> $'Rank: {x[0],3} ({x[1].Value} entries) {x[1].Key}')
end.
</syntaxhighlight>
{{out}}
<pre>
Rank: 1 (1682 entries) Phix
Rank: 2 (1675 entries) Wren
Rank: 3 (1652 entries) Julia
Rank: 4 (1622 entries) Raku
Rank: 5 (1577 entries) Nim
Rank: 6 (1552 entries) Go
Rank: 7 (1548 entries) Perl
Rank: 8 (1531 entries) Python
Rank: 9 (1416 entries) J
Rank: 10 (1343 entries) Java
</pre>
 
=={{header|Oz}}==
Line 3,719 ⟶ 3,768:
 
my $api =
MediaWiki::API->new( { api_url => 'http://rosettacode.org/mww/api.php' } );
 
my @languages;
Line 3,756 ⟶ 3,805:
</syntaxhighlight>
{{out}}
<pre> 1. GoPhix - 11771576
2. PhixWren - 11161569
3. Perl 6Julia - 11071540
4. Julia Raku - 11031520
5. Python Go - 10801500
6. Kotlin Perl - 10531468
7. RacketPython - 10451422
8. Perl Nim - 10451403
9. CJ - 9691278
10. Zkl C - 9601213
...</pre>
 
Line 4,028 ⟶ 4,077:
$languages = [regex]::matches($response,'title="Category:(.*?)">') | foreach {$_.Groups[1].Value}
 
$response = [Net.WebClient]::new().DownloadString("http://rosettacode.org/mww/index.php?title=Special:Categories&limit=5000")
$response = [regex]::Replace($response,'(\d+),(\d+)','$1$2')
 
Line 4,060 ⟶ 4,109:
Rank: 10 (960 entries) Zkl
</pre>
 
===PowerShell: Using MediaWiki API method===
{{trans|Python}}
Line 4,498 ⟶ 4,548:
 
=={{header|R}}==
 
{{incorrect|R|I believe you need to use <tt>continue gcmcontinue</tt> to get complete results.}}
<syntaxhighlight lang="rsplus">
library(rvest)
library(plyr)
library(dplyr)
options(stringsAsFactors=FALSE)
 
# getting the required table from the rosetta website
langUrl <- "http://rosettacode.org/mw/api.php?format=xml&action=query&generator=categorymembers&gcmtitle=Category:Programming%20Languages&prop=categoryinfo&gcmlimit=5000"
langUrl <- "https://rosettacode.org/wiki/Rosetta_Code/Rank_languages_by_popularity/Full_list"
langs <- html(langUrl) %>%
langs <- read_html(langUrl) %>%
html_nodes('page')
html_nodes(xpath='/html/body/div/div/div[1]/div[3]/main/div[2]/div[3]/div[1]/table') %>%
html_table() %>%
data.frame() %>%
select(c("Rank","TaskEntries","Language"))
 
 
# changing the columns to required format
langs$Rank = paste("Rank: ",langs$Rank)
langs$TaskEntries = paste0("(", format(langs$TaskEntries, big.mark = ",")
," entries", ")")
 
names(langs) <- NULL
 
langs[1:10,]
 
ff <- function(xml_node) {
language <- xml_node %>% html_attr("title")
language <- sub("^Category:", "", language)
npages <- xml_node %>% html_nodes('categoryinfo') %>%
html_attr("pages")
c(language, npages)
}
tbl <- ldply(sapply(langs, ff), rbind)
names(tbl) <- c("language", "n")
tbl %>%
mutate(n=as.integer(n)) %>%
arrange(desc(n)) %>%
head
</syntaxhighlight>
{{out|Output (as of MarchOctober, 2324, 20192022)}}
<pre>
1 Rank: 1 (1,589 entries) Phix
language n
12 Rank: 1 (1,589 entries) Go 1114Wren
3 Rank: 3 (1,552 entries) Julia
2 Perl 6 1059
4 Rank: 4 (1,535 entries) Raku
3 Kotlin 1029
5 Rank: 5 (1,500 entries) Go
4 Phix 993
6 Rank: 6 (1,485 entries) Perl
5 Julia 992
7 Rank: 7 (1,422 entries) Python
6 Perl 978
8 Rank: 8 (1,402 entries) Nim
9 Rank: 9 (1,293 entries) J
10 Rank: 10 (1,213 entries) C
</pre>
 
Line 6,339 ⟶ 6,392:
0 Examples - WML
0 Examples - VAX Assembly</pre>
 
=={{header|Visual Basic .NET}}==
Uses Web scrapping to get the information from the Languages category page - as this now shows the number of pages in each category with the non-task pages separated, there is no need to access other pages.<br>
It may be necessary to set the Security Protocol to Tls12 at the start of the Main method in order to run this - see the "Problem running the C# entry" section on the [[Talk:Rosetta Code/Count examples]] page.
<syntaxhighlight lang="vbnet">
Imports System.Collections
Imports System.Collections.Generic
Imports System.Net
Imports System.Text.RegularExpressions
 
Module RankLanguagesByPopularity
 
Private Class LanguageStat
Public name As String
Public count As Integer
Public Sub New(name As String, count As Integer)
Me.name = name
Me.count = count
End Sub
End Class
 
Private Function CompareLanguages(x As LanguageStat, y As languageStat) As Integer
Dim result As Integer = 0
If x IsNot Nothing Or y IsNot Nothing Then
If x Is Nothing Then
result = -1
ElseIf y Is Nothing
result = 1
Else
result = - x.count.CompareTo(y.count) ' Sort descending count
If result = 0 Then
result = x.name.CompareTo(y.name) ' Sort ascending name
End If
End If
End If
Return result
End Function
 
Public Sub Main(ByVal args As String())
 
Dim languages As New List(Of LanguageStat)
Dim basePage As String = "https://rosettacode.org/wiki/Category:Programming_Languages"
Dim nextPage As String = basePage
 
Dim nextPageEx = New RegEx("<a href=""/wiki/Category:Programming_Languages([?]subcatfrom=[^""]*)""")
Dim languageStatEx = _
New Regex(">([^<]+?)</a>[^<]*<span title=""Contains *[0-9,.]* *[a-z]*, *([0-9,.]*) *page")
 
Do While nextPage <> ""
Dim wc As New WebClient()
Dim page As String = wc.DownloadString(nextPage)
 
nextPage = ""
For Each link In nextPageEx.Matches(page)
nextPage = basePage & link.Groups(1).Value
Next link
 
For Each language In languageStatEx.Matches(page)
Dim lCount As Integer = 0
Dim lName As String = language.Groups(1).Value
Dim countText As String = language.Groups(2).Value.Replace(",", "").Replace(".", "")
If Not Integer.TryParse(countText, lCount)
Console.Out.WriteLine(lName & "Invalid page count: <<" & countText & ">>")
Else
languages.Add(New LanguageStat(lName, lCount))
End If
Next language
Loop
 
languages.Sort(AddressOf CompareLanguages)
 
Dim prevCount As Integer = -1
Dim prevPosition As Integer = -1
Dim position As Integer = 0
For Each stat As LanguageStat In languages
position += 1
If stat.count <> prevCount Then
prevPosition = position
prevCount = stat.Count
End If
Console.Out.WriteLine(prevPosition.ToString.PadLeft(4) & ": " &
stat.count.ToString.PadLeft(4) & " " & stat.name)
Next stat
 
End Sub
 
End Module
</syntaxhighlight>
{{out}}
Sample output as at 11th September 2023
<pre>
1: 1652 Phix
1: 1652 Wren
3: 1614 Julia
4: 1595 Raku
5: 1576 Nim
6: 1546 Go
7: 1531 Perl
8: 1470 Python
9: 1375 J
10: 1285 C
. . .
</pre>
 
=={{header|Wren}}==
Line 6,345 ⟶ 6,501:
{{libheader|Wren-fmt}}
An embedded program so we can use libcurl.
<syntaxhighlight lang="ecmascriptwren">/* rc_rank_languages_by_popularityRosetta_Code_Rank_languages_by_popularity.wren */
 
import "./pattern" for Pattern
Line 6,383 ⟶ 6,539:
}
 
var p1 = Pattern.new("> <a href/=\"//wiki//Category:+1^\"\" title/=\"Category:[+1^\"]\">+1^,, [+1^ ] page")
var unescs = [
var p2 = Pattern.new("subcatfrom/=[+1^#/#mw-subcategories]\"")
["_", " "],
["\%2B", "+"],
["\%C3\%A9", "é"],
["\%C3\%A0", "à"],
["\%C5\%8D", "ō"],
["\%C3\%A6", "æ"],
["\%CE\%9C", "μ"],
["\%D0\%9C\%D0\%9A", "МК"],
["\%E0\%AE\%89\%E0\%AE\%AF\%E0\%AE\%BF\%E0\%AE\%B0\%E0\%AF\%8D", "உயிர்"]
]
 
var unescapefindLangs = Fn.new { |text|
var url = "https://rosettacode.org/w/index.php?title=Category:Programming_Languages"
for (u in unescs) text = text.replace(u[0], u[1])
var subcatfrom = ""
return text
var langs = []
while (true) {
var content = getContent.call(url + subcatfrom)
var matches1 = p1.findAll(content)
for (m in matches1) {
var name = m.capsText[0]
var tasks = Num.fromString(m.capsText[1].replace(",", ""))
langs.add([name, tasks])
}
var m2 = p2.find(content)
if (m2) subcatfrom = "&subcatfrom=%(m2.capsText[0])" else break
}
return langs
}
 
var langs = findLangs.call()
var url1 = "https://rosettacode.org/wiki/Category:Programming_Languages"
langs.sort { |a, b| a[1] > b[1] }
var content1 = getContent.call(url1)
System.print("Languages with most examples as at 3 February, 2024:")
var p1 = Pattern.new("<li><a href/=\"//wiki//Category:[+1^\"]\"")
var matches1 = p1.findAll(content1)
var languages = matches1.map { |l| unescape.call(l.capsText[0]) }.toList[0..-4] // the last 3 are spurious
var p2 = Pattern.new("\">[+1^<]<//a>\u200f\u200e ([/d~,#03/d] member~s)")
var url2 = "http://rosettacode.org/mw/index.php?title=Special:Categories&limit=4000"
var content2 = getContent.call(url2)
var matches2 = p2.findAll(content2)
var results = []
for (m in matches2) {
var language = m.capsText[0]
if (languages.contains(language)) {
var numEntries = Num.fromString(m.capsText[1].replace(",", ""))
results.add([language, numEntries])
}
}
results.sort { |a, b| a[1] > b[1] }
System.print("Languages with most entries as at 4 January, 2022:")
var rank = 0
var lastScore = 0
var lastRank = 0
for (i in 0...resultslangs.count) {
var pair = resultslangs[i]
var eq = " "
rank = i + 1
Line 6,437 ⟶ 6,581:
<br>
We now embed this script in the following C program, build and run.
<syntaxhighlight lang="c">/* gcc rc_rank_languages_by_popularityRosetta_Code_Rank_languages_by_popularity.c -o rc_rank_languages_by_popularityRosetta_Code_Rank_languages_by_popularity -lcurl -lwren -lm */
 
#include <stdio.h>
Line 6,611 ⟶ 6,755:
WrenVM* vm = wrenNewVM(&config);
const char* module = "main";
const char* fileName = "rc_rank_languages_by_popularityRosetta_Code_Rank_languages_by_popularity.wren";
char *script = readFile(fileName);
WrenInterpretResult result = wrenInterpret(vm, module, script);
Line 6,632 ⟶ 6,776:
Showing just the top thirty.
<pre>
Languages with most entriesexamples as at 43 JanuaryFebruary, 20222024:
1 PhixWren 1,499665
2 1 = WrenPhix 1,467665
3 Julia 1,466638
4 Raku 1,446608
5 Go Nim 1,440576
6 PerlGo 1,408547
7 Nim Perl 1,399540
8 Python 1,341497
9 CJ 1,185413
10 REXXJava 1,150318
11 KotlinC 1,132293
12 JavaC++ 1,126258
13 HaskellRuby 1,111235
14 Mathematica 1,109200
15 Ruby FreeBASIC 1,086185
16 Racket Haskell 1,082166
17 C++ REXX 1,079152
18 J Kotlin 1,062143
19 Zkl Racket 1,012099
20 FreeBASICJq 978 1,081
2021 = D Sidef 9781,051
22 Tcl11l 9771,016
23 FactorZkl 953 1,011
24 SidefFactor 9451,001
25 11lD 931 990
26 ScalaALGOL 68 916986
27 CTcl sharp 907 983
28 AdaScala 860948
29 RustDelphi 851945
30 PicoLispAda 839 940
30 = Rust 940
</pre>
 
58

edits