Model based software development - F 2025 (Metamodeling & Typing)

Quiz for the course "Model based software development" 2025, with focus on types.


Click the button to start the quiz

Start Quiz

<- Leave quiz



Questions in the quiz (10)


What xtext code fits the diagram?

  • ElementA: "A" name=ID;
    ElementB: "A";
    ElementC: "B";

What xtext code fits the diagram?

  • ElementA: "A" name=ID;
    ElementB: "B" name=ID contains=ElementA;
    ElementC: "C" name=ID;

What xtext code fits the diagram?

  • ElementA: {ElementB} "A" name=ID;
    ElementB: "B" name=ID;
    ElementC: "C" name=ID;

What xtext code fits the diagram?

  • ElementA: ({ElementB} "B" | {ElementC} "C") name=ID;
    ElementB: "B" name=ID;
    ElementC: "C" name=ID;

  • ElementA: ID ElementB|ElementC;
    ElementB: "B" name=ID;
    ElementC: "C" name=ID;

What xtext code fits the diagram?

  • ElementA: {ElementB} "A" name=ID;
    ElementB: {ElementC} "B" name=ID;
    ElementC: "C" name=ID;

What xtext code fits the diagram?

  • ElementA: name=ID contains+=(ElementB|ElementC);
    ElementB: "B" name=ID;
    ElementC: "C" name=ID;

What xtext code fits the diagram?

  • Model: types+=Type;
    Type: BaseType|SubType;
    BaseType: name=ID;
    SubType: name=ID;

What xtext code fits the diagram?

  • ElementA: name=ID contains+=(ElementB|ElementC);
    ElementB returns TypeA: "B" name=ID ({SubTypeA.left = current} "*" right=Atom)?;
    ElementC returns TypeA: "C" name=ID ({SubTypeB.left = current} "+" right=Atom)?;
    Atom: Number;

What xtext code fits the diagram?

  • ElementA: name=ID contains+=(ElementB|ElementC);
    ElementB returns TypeA: "B" name=ID;
    ElementC returns TypeA: "C" name=ID;

What xtext code fits the diagram?

  • ElementA: "A" name=ID;
    ElementB: "B" name=ID;
    ElementC: "C" name=ID;