You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/index.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,6 @@ layout: default
5
5
title: Sample Programs in Every Language
6
6
---
7
7
8
-
Welcome to Sample Programs in Every Language, a collection of code snippets in as many languages as possible. Thanks for taking an interest in our collection which currently contains 1150 articles written by 260 authors.
8
+
Welcome to Sample Programs in Every Language, a collection of code snippets in as many languages as possible. Thanks for taking an interest in our collection which currently contains 1151 articles written by 260 authors.
9
9
10
10
If you'd like to contribute to this growing collection, check out our [contributing document](https://github.com/TheRenegadeCoder/sample-programs/blob/master/.github/CONTRIBUTING.md) for more information. In addition, you can explore our documentation which is organized by [project](/projects) and by [language](/languages). If you don't find what you're look for, check out our list of related [open-source projects](/related). Finally, if code isn't your thing but you'd still like to help, there are plenty of other ways to [support the project](https://therenegadecoder.com/updates/5-ways-you-can-support-the-renegade-coder/).
Copy file name to clipboardExpand all lines: docs/languages/index.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ layout: default
6
6
title: Programming Languages
7
7
---
8
8
9
-
Welcome to the Languages page! Here, you'll find a list of all of the languages represented in the collection. At this time, there are 154 languages, of which 153 are tested, 1 is untestable, and 959 code snippets.
9
+
Welcome to the Languages page! Here, you'll find a list of all of the languages represented in the collection. At this time, there are 154 languages, of which 153 are tested, 1 is untestable, and 960 code snippets.
10
10
11
11
## Language Collections by Letter
12
12
@@ -253,7 +253,7 @@ The 'O' collection contains 7 languages, of which 7 are tested, and 33 code snip
253
253
254
254
### P
255
255
256
-
The 'P' collection contains 14 languages, of which 14 are tested, and 128 code snippets.
256
+
The 'P' collection contains 14 languages, of which 14 are tested, and 129 code snippets.
Welcome to the [Baklava](https://sampleprograms.io/projects/baklava) in [Prolog](https://sampleprograms.io/languages/prolog) page! Here, you'll find the source code for this program as well as a description of how the program works.
26
+
27
+
## Current Solution
28
+
29
+
{% raw %}
30
+
31
+
```prolog
32
+
:- initialization(main).
33
+
34
+
baklava(N, NE) :-
35
+
forall(between(N, NE, X), baklava_line(X)).
36
+
37
+
baklava_line(N) :-
38
+
NSP is abs(N),
39
+
NST is 21 - 2 * NSP,
40
+
output_repeat(" ", NSP),
41
+
output_repeat("*", NST),
42
+
nl.
43
+
44
+
output_repeat(S, N) :-
45
+
forall(between(1, N, _), write(S)).
46
+
47
+
main() :-
48
+
baklava(-10, 10),
49
+
halt.
50
+
51
+
```
52
+
53
+
{% endraw %}
54
+
55
+
Baklava in [Prolog](https://sampleprograms.io/languages/prolog) was written by:
56
+
57
+
- rzuckerm
58
+
59
+
If you see anything you'd like to change or update, [please consider contributing](https://github.com/TheRenegadeCoder/sample-programs).
60
+
61
+
## How to Implement the Solution
62
+
63
+
No 'How to Implement the Solution' section available. [Please consider contributing](https://github.com/TheRenegadeCoder/sample-programs-website).
64
+
65
+
## How to Run the Solution
66
+
67
+
No 'How to Run the Solution' section available. [Please consider contributing](https://github.com/TheRenegadeCoder/sample-programs-website).
0 commit comments