@grahamdearsley
Forum Replies Created
-
AuthorPosts
-
Yep Ed. Variables, loops, conditional branches and then array and string handling. After that its mostly language specifics and GCE maths ?
November 8, 2018 at 3:02 pm in reply to: Read First if flying on a Boeing 737 Max–or maybe not! #28082737’s have been falling out of the sky for years. The biggest problem was reported total control lock up causing crashes. Boeing investigated after each crash but found nothing wrong every time so they just changed things that may have been the cause and hoped for the best. It wasn’t until they fitted a bigger rudder servo that the problem seemed to stop.
I just read back my last reply and it seems to be a bit negative, it was not meant to be !
Keep up the good work ?
The full program in C/C++ would be as below (Note the use of point_total += instead of point_total = point_total but either will work)
#include “pch.h”
#include <iostream>
using namespace std;
int main()
{
int exercises_completed = 13;
int points_per_exercise = 5;
int point_total = 100;
cout << “Old Total = ” << point_total << endl;
point_total += exercises_completed * points_per_exercise;
cout << “New Total = ” << point_total << endl;
}
I am not familiar with Python syntax but as they asked you to “update” point_total you probably don’t need a new variable. The syntax in BASIC would be :
point_total=point_total+(exercises_completed*points_per_exercise)
One advantage USB headphones can share with digital active speakers is that the DAC/Amp can be tuned to the drivers they are hooked to because they will never be connected to anything else. With a HiFi Amp and passive speakers they can only try to have as flat a response as possible.
The sample was about 20k people but with the best will in the world they could not get a representative sample. Imagine the conversation.
C4.
Hello, were from C4 television and we are conducting a survey…
Leaver.
Im sorry I just remembered I have to de-flea the dog, Goodbye.
If the sun did a Brexit survey in Liverpool then the result would be about 98% leave because only a tiny number of remainers would even talk to them !
Add to that that the biggest number of Remainers are under 30 and they have the lowest turnout (cant be arsed) in any election and I have little doubt what the result of a Second “Peoples Vote” would be.
Apparently I am buying a fair amount of jewelry on ebay and paying with my paypal account these days. I must be because I keep getting delivery confirmation emails. Of course if im not happy I can always click a provided link. Or I can logon to ebay or paypal directly and find its a load of tosh.
Now what to do ?
Quite a surprise on the C4 Referendum vote program. They only managed to get 56% of the people they interviewed to agree with them ! That pretty much guarantees that an actual vote would come out massively in favour of leave doesn’t it ?
Maybe I should start a new Retro programming thread like MM Retro Mart ?
No i’m not writing drafts. I am writing on my phone though. Don’t matter much cos my opinion of Commodore Basic is still clear ?. Every Commodore basic listing is full of pokes because it didn’t even try to support the hardware. They had another go on the C128 with V2.0 but it was still rubbish. Dont matter now but it was dire.
What is with the HTML mark up ?
<p style=”text-align: left;”>Oh yucky Commodore basic. Made in 1977 from an M$ lisence. It was rubbish on the Pet and then they put it on the C64.</p>
Oops ?
<p style=”text-align: left;”>The point is that memory and line numbers and variables will stay the same with enter but not with LOAD.</p>
You can break any sort of programming rules in Atari Basic. Self modifying is a good one. Just use the ENTER command in your program and it will pull in new code from a file, tokenise it and go on as before.
Reading you link about overflows turned up another unexpected thing about Atari BASIC Ed. If I do a calculation on a variable and the result won’t fit in 8 bytes of signed floating point then I get a strange number with an E in it as the result. It turns out that this is scientific notation and in this case it is 10 to the power of n and the E stands for exponent. I have been aware of scientific notation since my collage days but I never made the connection before.p
I am not a great fan of C++ myself. In fact the more I learn about it the more overly complex it appears. The main push is towards encapsulating everything into objects that can be seen as stand alone building blocks.
The thing is though I am increasingly reading texts that assume I have some knowlage of C++ methods so I thought I should give it a go. About 95% of Windows is written in C with 3% in C++ and 2% in assembly. Microsoft has stated that it will be increasing the use of C++ in the future though. Stand by for some bugs ?
I can’t personally comment on Pascal because of my very limited knowlage of it but Lazarus looks like a top notch IDE. I would not set out to learn Pascal from scratch now though. Existing Pascal programmers can reportedly earn good money maintaining code that was originally written to run on 1970s main frames but it is not a language of the future.
One thing I like about Visual Studio as a development tool is that it does on the fly compilation in the background as you type. This capability was originally developed for Visual Basic but it has now been extended to C++ and Java. Visual Studio will highlight errors in your syntax AND your logic with a squiggly line as you type. Even better than an interpreted language in many ways.
You still have to build your project before you can run it though.
-
AuthorPosts
