0% found this document useful (0 votes)
33 views

Machine Problem 11 - Loops

The document provides instructions for a MATLAB programming assignment. Students are asked to write a script that prompts the user to input a number from 1-9, then uses a for loop to display that number of asterisks in a figure. They must save their file with a specific naming convention, include header comments, and submit both the script file and a PDF with screenshots of their work. The objectives are to familiarize students with the MATLAB interface and basic operations like for loops.
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
33 views

Machine Problem 11 - Loops

The document provides instructions for a MATLAB programming assignment. Students are asked to write a script that prompts the user to input a number from 1-9, then uses a for loop to display that number of asterisks in a figure. They must save their file with a specific naming convention, include header comments, and submit both the script file and a PDF with screenshots of their work. The objectives are to familiarize students with the MATLAB interface and basic operations like for loops.
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

CS10-8L: Computer Programming Laboratory

Machine Problem #11: For Loops

Name: Score:

Section: Date:

OBJECTIVES
● To familiarize the students with the MATLAB interface.

● To enable the students to use some basic operations.

Instructions:
1. Save your file as Surname_Firstname_MP11. Ex. Isip_Cheryl_MP11

2. You will submit a zip file containing the following and send it to BB.

a. PDF file of Machine Problem 11 provided with the screenshot of your answers.
b. MATLAB script with .m extension.

3. Your program must have comments for each section.


Header Comments:
%{
This demo program shows how good a MATLAB program is
Written by: Cheryl Isip
Date: August 27,2021
Time: 2:20pm
Program: BSIE
Course: CS10-8L
Section: B20
School: Mapua University
%}

MACHINE PROBLEM

1. Write a script that will prompt the user to input a number from 1 – 9 only and display the
figure below.

Prepared by: Cheryl Mari M. Isip, Mapua University


CS10-8L: Computer Programming Laboratory
Machine Problem #11: For Loops

In the editor window, take a screenshot and paste your output:

Prepared by: Cheryl Mari M. Isip, Mapua University


CS10-8L: Computer Programming Laboratory
Machine Problem #11: For Loops

In the command window, take a screenshot and paste your output:

Prepared by: Cheryl Mari M. Isip, Mapua University

You might also like