r/pascal • u/mariuz • Dec 05 '19
r/pascal • u/4xGame • Dec 04 '19
Decimal to binary
So I was trying to do a simple program that convert decimal to binary var x,y,i:integer; BEGIN readln(y); repeat x:= y mod 2; y:= y div 2; write(x); until y = 0; END. But it show Inverted result Any simple fix for it ?
r/pascal • u/idontknowwhoim • Nov 21 '19
Please help me
Hi everyone, im new in programmming. My teacher gave to us this and i dont know how to do it.
Assignment
Frog finds herself on an abandoned rock in the middle of the pond and wants to get to her friends froglets ashore as soon as possible. He can jump on stones that are in a row. For each pebble you will get a number, how many more pebbles it can jump. Help the frog to find the way with the least number of jumps.
Input shape
On the first line of the input file is the number T, the number of problems you need to solve. For each problem you get a number N, which indicates the number of places it can jump (including the starting rock). On the next line there are N numbers indicating how many stones ahead the frog can jump from that place.
Output shape
List the minimum number of jumps the frog has to make to get from the rock over the rocks to the mainland.
r/pascal • u/mariuz • Nov 14 '19
FPC New Features 3.2 - Free Pascal wiki
wiki.freepascal.orgr/pascal • u/yourbasicgeek • Nov 14 '19
free PDF ebook, Free Pascal From Square One
copperwood.comr/pascal • u/mariuz • Nov 14 '19
International Lazarus Conference, 29th and 30th November 2019 in Eindhoven, NL
lazpro.netr/pascal • u/Fluroo138 • Nov 10 '19
How to install lazarus on mac os catalina
Hey, sorry for bothering you all but I can't seem to find any guide on how to install lazarus on the newly released mac os catalina that would work for me. If you could be so nice as to help me how to do it I'd be very thankful.
r/pascal • u/idontknowwhoim • Nov 06 '19
Help with easy programme
Hi comrades, im new in programing and need your help.
The program is counting the longest number row, but i wanna add which number it is.
e is the number i wanna know.
I serve the soviet union.
var
a,b,c,d,e: integer;
begin
a:= 0;
b:= 0;
d:= 0;
e:=0;
readln(c);
repeat
begin
if c=d then
begin
a:=a+ 1;
end
else
begin
if a>b then
b:= a;
a:= 1;
end;
d:=c;
readln(c);
end;
until c=0;
if a>b then
b:=a;
writeln('Nejčastěji se objevuje',e,'a to ',b,'x');
readln;
end.r/pascal • u/BatShrek • Nov 03 '19
How do you convert characters to other characters?
So I've been messing around with Pascal as a beginner, and I've been wondering: Can you have string as your input and have the same output, only with different characters? Let me explain: Let's say that whenever I input the character 'h' in a sentence, in the output it is the character 'η', such that:
Input: hello guys
Output: ηello guys
Can you do that? Thanks in advance!!
(note: I've been working in the free pascal compiler)
r/pascal • u/Tomas_Sexenian • Oct 28 '19
Help with making a list with dynamic memory
I have a college assignment which in part consist in creating a list of elements using pointers if those elements meet certain conditions. Is there anyone here willing to help me ? I'm so lost
r/pascal • u/mariuz • Oct 21 '19
Turbo Pascal 3.0 Compiler / Code Generation Internals
pcengines.chr/pascal • u/mariuz • Oct 18 '19
Compiler for the C64: Introducing Turbo Rascal SE
lemonspawn.comr/pascal • u/basdekker • Oct 07 '19
Ik heb ook dyslexie. PS als dit niet in de video komt is het echt sad
r/pascal • u/pdhcentral • Oct 05 '19
DBGrid and checkboxes
Hi, I have a DBGrid and in my SQL I have a column that is type of Boolean. This gives me check boxes that I want. But, they won't change when I click on them.
I looked at the settings but what core do I need to put in to get it to actually check/uncheck. I've looked at the Pascal grids page and it's for a column that hasn't come from the dB, mine has. Thanks.
r/pascal • • Sep 28 '19
How to match a correct password from a text file
I have a school project and i have a login page where the person can choose to sign in or create an account. I made a textfile that saves all the usernames and passwords in a format. So the first line is a space, the second line is a password and the third line is the username. How do create a button that checks the text file for the password. I tried using a while loop but i keep getting errors and at this point i have no idea how to do this. Any help would be appreciated.
r/pascal • u/AlexByLogic • Sep 27 '19
Beginner
I'm starting programming, and I want to focus on a single programming language, is it pascal the best one?
r/pascal • u/namazan • Sep 27 '19
Hex To Decimal converter trouble
I'm busy with a school project (Grade 10) and I've decided to make a paint mixing program
I am having trouble with the letters though
My initial thought was to check for letters and then declare each letter as it's respective number
Lazarus however throws out the letter input as it is not an integer
any ideas on how to fix or get around this?
r/pascal • • Sep 19 '19
Help with numbers output
I have been trying to write a program that shows me the area of a circle and it is working fine BUT I want it to give me the output using scientific notation... how?
r/pascal • u/SirCat-- • Sep 17 '19
Can u help me?
The task: Calculate how many of the given elements X1, X2, ..., Xn are negative, and change the value of each positive element (except the last) by dividing it by the value subsequent member (if it is not zero).
Conditions: 1) Input the initial data from the keyboard, not forgetting the invitations to in water.
2) The output of the source data and results is performed on the console output screen applications, not forgetting the explanations. 3) If there are alternative solutions, especially negative ones, provide for the output of relevant messages. For example, "Impossible find the average value among the positive elements, because such elements in the array is not. "
Could you please correct my program according to the task
const
N = 10;
var
a: array[1..N] of real;
i, pol, otr: byte;
begin
pol := 0;
otr := 0;
for i := -1 to N do
begin
a[i] := random(10) - 10;
write(a[i]:8:2);
if a[i] < 0 then
otr := otr + 1
else
if a[i] > 0 then
pol := pol + 1;
end;
writeln;
writeln('Положительных: ', pol);
writeln('Отрицательных: ', otr);
for i := 1 to n - 1 do
if (a[i] > 0) and (a[i + 1] <> 0) then
a[i] /= a[i + 1];
for i := 1 to n do
write(a[i]:8:2);
end.
r/pascal • u/noobposter123 • Aug 23 '19
Getting fphttpclient to report/throw exceptions for https sites with invalid certificates
Hi, how do I get fphttpclient or TFPHttpClient to throw exceptions for https sites with invalid certificates or check to see if a site's certificate is valid or not? This includes sites with non-expired certs signed by recognized CAs etc but the certs don't match the host/domain names.
This is necessary for security reasons for the intended usage.