Question

I'm writing a multiple choice test program for teachers. The formula for the marks is:

(points awarded) / (maximum score) * 5 + 1.

This gives a mark in the range [1,6].

Now I want to add a scripting language, with which a teacher can define the formula for the mark him/herself.

Assuming the teacher is a person that doesn't know a lot about programming, which programming language would be the best choice to integrate as scripting language (from the standpoint of simplicity of use)?

Some of the possible choices are:

  • JavaScript
  • Python
  • Lua
  • VB.NET
  • C#
  • Ruby
  • Vala

My natural tendency would be towards JavaScript or Python. However, I am a bit wary as those 2 languages are case-sensitive programming languages.

The only case-insensitive option I am aware of would be VB.NET. Are there any other good choices?

Was it helpful?

Solution

Why do you need a whole programming language to calculate the mark?

Simply use your programming language of choice to create a nice interface where the teachers have some flexibility.

You could for example have a simple input and allow the teachers to enter in some variable you've already defined, maybe $points and $max_score as well as a few basic math operators (*/-+) and then you can read the input and interpret it.

Alternatively you could use drop downs and other control to have a finer level of control, the options here are really only limited by your imagination.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top