Escrito por estudiantes que aprobaron Inmediatamente disponible después del pago Leer en línea o como PDF ¿Documento equivocado? Cámbialo gratis 4,6 TrustPilot
logo-home
Document preview thumbnail
Vista previa 2 fuera de 9 páginas
Examen

Fortran Good Programming Tips UPDATED ACTUAL Exam Questions and CORRECT Answers

Document preview thumbnail
Vista previa 2 fuera de 9 páginas

Fortran Good Programming Tips UPDATED ACTUAL Exam Questions and CORRECT Answers What should your stop statement do? - CORRECT ANSWER and return a code of 0. Done via the stop 0 command - Terminates the program What is one way of checking if your program ran sucessfully? - CORRECT ANSWER using the echo $? on command line. See if it prints out the value next to your stop statement What statement must all your programs have? - CORRECT ANSWER Your variable names should - CORRECT ANSWER - be very descriptive What should be included in your declaration section for more clarity with user? - CORRECT ANSWER - Variable dictionary that provides the name of the variable, and its units What is critical when naming variables? - CORRECT ANSWER value assigned to them before they can be used in an expression What errors occur when you fail to assign a value to a value and use it in an expression? - CORRECT ANSWER - Execution-time error or run-time error -

Vista previa del contenido

Fortran Good Programming Tips
UPDATED ACTUAL Exam Questions and
CORRECT Answers
What should your stop statement do? - CORRECT ANSWER - Terminates the program
and return a code of 0.


Done via the stop 0 command


What is one way of checking if your program ran sucessfully? - CORRECT ANSWER -
using the echo $? on command line. See if it prints out the value next to your stop statement


What statement must all your programs have? - CORRECT ANSWER - implicit none



Your variable names should - CORRECT ANSWER - be very descriptive


What should be included in your declaration section for more clarity with user? - CORRECT
ANSWER - Variable dictionary that provides the name of the variable, and its units



What is critical when naming variables? - CORRECT ANSWER - Variables MUST have a
value assigned to them before they can be used in an expression


What errors occur when you fail to assign a value to a value and use it in an expression? -
CORRECT ANSWER - Execution-time error or run-time error


Say a program you want to write has a constant (g = 9.81 m/s^2), how would you use this in the
program? - CORRECT ANSWER - Make g a parameter that cannot change value. Done
via the statement


real, parameter :: G = 9.81

, Make your parameters uppercase to make them visually apparent


What are binary operators? - CORRECT ANSWER - They require two "operands" or two
inputs to work


+ (addition), - (subtraction), * (multiplication), / (division)


Unary Operators - CORRECT ANSWER - require only one operand. Includes only the +
and - operators to assign signs to numbers


Arithmetic Operator Rules - CORRECT ANSWER - 1) No two operators may occur
sequentially


2) Negative values cannot be exponentiated to a non-integer power or a negative power


3) Division by zero is not permissible


a*-b - CORRECT ANSWER - illegala



a*(-b) - CORRECT ANSWER - legal



a**-2 - CORRECT ANSWER - illegal



a**(-2) - CORRECT ANSWER - legal



(-1.0)**2 - CORRECT ANSWER - legal

Información del documento

Subido en
30 de marzo de 2025
Número de páginas
9
Escrito en
2024/2025
Tipo
Examen
Contiene
Preguntas y respuestas
$10.99

¿Documento equivocado? Cámbialo gratis Dentro de los 14 días posteriores a la compra y antes de descargarlo, puedes elegir otro documento. Puedes gastar el importe de nuevo.
Escrito por estudiantes que aprobaron
Inmediatamente disponible después del pago
Leer en línea o como PDF

Seller avatar
Los indicadores de reputación están sujetos a la cantidad de artículos vendidos por una tarifa y las reseñas que ha recibido por esos documentos. Hay tres niveles: Bronce, Plata y Oro. Cuanto mayor reputación, más podrás confiar en la calidad del trabajo del vendedor.
MGRADES
3.8
(247)
Vendido
1489
Seguidores
106
Artículos
103280
Última venta
23 horas hace



Por qué los estudiantes eligen Stuvia

Creado por compañeros estudiantes, verificado por reseñas

Calidad en la que puedes confiar: escrito por estudiantes que aprobaron y evaluado por otros que han usado estos resúmenes.

¿No estás satisfecho? Elige otro documento

¡No te preocupes! Puedes elegir directamente otro documento que se ajuste mejor a lo que buscas.

Paga como quieras, empieza a estudiar al instante

Sin suscripción, sin compromisos. Paga como estés acostumbrado con tarjeta de crédito y descarga tu documento PDF inmediatamente.

Student with book image

“Comprado, descargado y aprobado. Así de fácil puede ser.”

Alisha Student

Preguntas frecuentes