", "encodingFormat": "text/html", "comment": { "@type": "Comment" } } ], "suggestedAnswer": [ { "@type": "Answer", "position": 0, "text": " ... ", "encodingFormat": "text/html", "comment": { "@type": "Comment", "text": "" } }, { "@type": "Answer", "position": 1, "text": " ... ", "encodingFormat": "text/html", "comment": { "@type": "Comment", "text": "" } }, { "@type": "Answer", "position": 2, "text": "", "encodingFormat": "text/html", "comment": { "@type": "Comment", "text": "" } }, { "@type": "Answer", "position": 3, "text": " ... ", "encodingFormat": "text/html", "comment": { "@type": "Comment", "text": "" } } ] }, { "@type": "Question", "eduQuestionType": "Multiple choice", "learningResourceType": "Exam exercise", "name": "", "text": "Welche Kontrollstruktur wird verwendet, um einen Codeblock wiederholt auszuführen, solange eine Bedingung wahr ist?", "encodingFormat": "text/html", "assesses": "", "acceptedAnswer": [ { "@type": "Answer", "position": 3, "text": "while", "encodingFormat": "text/html", "comment": { "@type": "Comment" } } ], "suggestedAnswer": [ { "@type": "Answer", "position": 0, "text": "switch", "encodingFormat": "text/html", "comment": { "@type": "Comment", "text": "" } }, { "@type": "Answer", "position": 1, "text": "for", "encodingFormat": "text/html", "comment": { "@type": "Comment", "text": "" } }, { "@type": "Answer", "position": 2, "text": "if", "encodingFormat": "text/html", "comment": { "@type": "Comment", "text": "" } }, { "@type": "Answer", "position": 3, "text": "while", "encodingFormat": "text/html", "comment": { "@type": "Comment", "text": "" } } ] }, { "@type": "Question", "eduQuestionType": "Multiple choice", "learningResourceType": "Exam exercise", "name": "", "text": "Was ist der Zweck der Funktion 'document.getElementById()'?", "encodingFormat": "text/html", "assesses": "", "acceptedAnswer": [ { "@type": "Answer", "position": 1, "text": "Ein HTML-Element mit einer bestimmten ID abzurufen", "encodingFormat": "text/html", "comment": { "@type": "Comment" } } ], "suggestedAnswer": [ { "@type": "Answer", "position": 0, "text": "Ein neues HTML-Element zu erstellen", "encodingFormat": "text/html", "comment": { "@type": "Comment", "text": "" } }, { "@type": "Answer", "position": 1, "text": "Ein HTML-Element mit einer bestimmten ID abzurufen", "encodingFormat": "text/html", "comment": { "@type": "Comment", "text": "" } }, { "@type": "Answer", "position": 2, "text": "Das DOM zu durchlaufen", "encodingFormat": "text/html", "comment": { "@type": "Comment", "text": "" } }, { "@type": "Answer", "position": 3, "text": "Den Inhalt eines HTML-Elements zu ändern", "encodingFormat": "text/html", "comment": { "@type": "Comment", "text": "" } } ] } ] }
Welche Kontrollstruktur wird in JavaScript verwendet, um Code nur auszuführen, wenn eine Bedingung erfüllt ist?
switch
if

Webentwicklung Übungen werden geladen ...