Java – a replacement for an existing school assignment

I have a school assignment that includes writing a scanner / lexical analyzer for a given simple language The scanner must be programmed in C

This type of task has been used since the 1990s. Although it is still a valid exception, I think it is a little old and boring

I have been allowed to propose new programming tasks It must have the same difficulty. It can be C, objective C or Java

Which direction should I take, with the same difficulty, but more modern, suitable for modern CS / life

thank you

Solution

I'm curious: who thinks this is out of date? Your professor? Is anyone famous in the analysis community? Or you?

Scanners and parsers are still related to professional software development and, more importantly, to computational science If you want to know about computers, you should know about scanners and parsers

However, if you are sure you should do other tasks, why not write a tool to generate scanners in C? You can provide a set of regular expressions defining syntax tags as input, which will generate a C program that can recognize the input tags Then you will never need to write the scanner again!

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>