100% tevredenheidsgarantie Direct beschikbaar na je betaling Lees online óf als PDF Geen vaste maandelijkse kosten
logo-home
CSE 240 Midterm Study ASU Gonzales Questions and Answers Latest Update 100% Correct. €7,88
In winkelwagen

Tentamen (uitwerkingen)

CSE 240 Midterm Study ASU Gonzales Questions and Answers Latest Update 100% Correct.

 0 keer verkocht
  • Vak
  • CSE 240
  • Instelling
  • CSE 240

What kind of error is in the following line:- int a = ((2*45)*(6/2) hello (4+90)); Lexical Error Semantic Error Correct! Syntactic Error None of the above - ️️What kind of error is in the following line:- int a = ((2*45)*(6/2) hello (4+90)); Lexical Error Semantic Error Syntactic Error...

[Meer zien]

Voorbeeld 4 van de 31  pagina's

  • 22 september 2024
  • 31
  • 2024/2025
  • Tentamen (uitwerkingen)
  • Vragen en antwoorden
  • CSE 240
  • CSE 240
avatar-seller
CSE 240 Midterm Study ASU Gonzales
What kind of error is in the following line:-
int a = ((2*45)*(6/2) hello (4+90));

Lexical Error
Semantic Error
Correct! Syntactic Error
None of the above - ✔️✔️What kind of error is in the following line:-
int a = ((2*45)*(6/2) hello (4+90));

Lexical Error
Semantic Error
Syntactic Error
None of the above

The syntactic structure of imperative programming languages normally include which of
the following units:

operators

keywords

identifiers

conditional statements

loop statements

variable declaration - ✔️✔️conditional statements

loop statements

variable declaration

The compiler execute the program.

True or False - ✔️✔️False

The semantic structure of imperative programming languages normally include which of
the following validations:

type matching

,division by zero

a variable name should start with a letter, '$' or '_'

parameters type in a function declaration should match these in the function call.

statement should end with a ';'

unicity - ✔️✔️type matching

parameters type in a function declaration should match these in the function call.

unicity

Compilation of a program is to execute all the statements of the program completely.

True or False - ✔️✔️True

During compilation, all the statements of a program in a high-level language are
converted (translated) to a low-level language (such as assembly language).

True or False - ✔️✔️True

This programming language uses two-step translation with intermediate codes for
execution.

C
C++
Java
C#
LISP - ✔️✔️Java

Interpretation of a program is the direct execution of one statement at a time
sequentially.

True or False? - ✔️✔️True

The lexical structure of all programming languages are similar and normally include
which of the following units

identifiers
loop statements
keywords
operators
literals - ✔️✔️identifiers

,keywords
operators
literals

What is a data type?

a specialized format for organizing and storing data

a storage location paired with an associated symbolic name

a piece of information

a set of primary values and the operations defined on these values - ✔️✔️a set of
primary values and the operations defined on these values

Considering the following code

struct emp {
int id;
char *name;
};
struct emp john;

Which of the following lines are correct?

int a = 1;
char b[ ] = "John Doe";
emp.id = a;
emp.name = b;
printf ("%d, %s", emp.id, emp.name);

int a = 1;
char b[ ] = "John Doe";
john.id = b;
john.name = a;
printf ("%d, %s", john.id, john.name);

int a = 1;
char b[ ] = "John Doe";
john.id = a;
john.name = b;
printf ("%d, %s", john.id, john.name);

int a = 1;
char b[ ] = "John Doe";
john[0].id = a;

, john[0].name = b;
printf ("%d, %s", john[0].id, john[0].name); - ✔️✔️int a = 1;
char b[ ] = "John Doe";
john.id = a;
john.name = b;
printf ("%d, %s", john.id, john.name);

Which code in C is equivalent to this code in Java

int x = 5;
float y = 10.3f;
System.out.println("hello " + x + " bye " + y);


int *x = 5;
float *y = 10.3;
printf("hello %p bye %p", x, y);

int x = 5;
float y = 10.3;
printf("hello %d bye %f", x, y);

int x = 5;
float y = 10.3;
printf("hello %d bye %f", &x, &y);

int x = 5;
float y = 10.3f;
printf("hello %i bye %f", x, y); - ✔️✔️int x = 5;
float y = 10.3;
printf("hello %d bye %f", x, y);

What is printed by the following code?

#include <stdio.h>

int i=10;

int bar(int m, int *n) {
printf("i=%d k=%d l=%d\n", i,m,*n);
}
int foo(int k, int *l) {
printf("i=%d k=%d l=%d\n", i,k,*l);
k = 3;
*l = 4;
bar(k, l);

Dit zijn jouw voordelen als je samenvattingen koopt bij Stuvia:

Bewezen kwaliteit door reviews

Bewezen kwaliteit door reviews

Studenten hebben al meer dan 850.000 samenvattingen beoordeeld. Zo weet jij zeker dat je de beste keuze maakt!

In een paar klikken geregeld

In een paar klikken geregeld

Geen gedoe — betaal gewoon eenmalig met iDeal, Bancontact of creditcard en je bent klaar. Geen abonnement nodig.

Focus op de essentie

Focus op de essentie

Studenten maken samenvattingen voor studenten. Dat betekent: actuele inhoud waar jij écht wat aan hebt. Geen overbodige details!

Veelgestelde vragen

Wat krijg ik als ik dit document koop?

Je krijgt een PDF, die direct beschikbaar is na je aankoop. Het gekochte document is altijd, overal en oneindig toegankelijk via je profiel.

Tevredenheidsgarantie: hoe werkt dat?

Onze tevredenheidsgarantie zorgt ervoor dat je altijd een studiedocument vindt dat goed bij je past. Je vult een formulier in en onze klantenservice regelt de rest.

Van wie koop ik deze samenvatting?

Stuvia is een marktplaats, je koop dit document dus niet van ons, maar van verkoper ACADEMICMATERIALS. Stuvia faciliteert de betaling aan de verkoper.

Zit ik meteen vast aan een abonnement?

Nee, je koopt alleen deze samenvatting voor €7,88. Je zit daarna nergens aan vast.

Is Stuvia te vertrouwen?

4,6 sterren op Google & Trustpilot (+1000 reviews)

Afgelopen 30 dagen zijn er 69411 samenvattingen verkocht

Opgericht in 2010, al 15 jaar dé plek om samenvattingen te kopen

Start met verkopen
€7,88
  • (0)
In winkelwagen
Toegevoegd