Write script to clear the variables in the workspace, Programming Languages

Write a script called 'prob2.m' that asks the user if they wish to clear the variables in the workspace. If the user responds with the strings 'y' or 'yes' then the workspace should be cleared. After the workspace is cleared the script should display the string 'Workspace cleared.' If the user responds with the strings 'n' or 'no' then the work space should not be cleared and the script should display the string 'Workspace not cleared.' If the user enters anything else, the script should say that the 'Input was not understood.' You should implement this using an if-else construction.

In the file 'hw4.m' first issue a command that lists all the variables currently in the workspace. Then execute execute 'prob2.m'. Finally, to see if your script did what it was supposed to, redisplay a list of all the variables in the workspace.

 

 

Posted Date: 3/22/2013 6:59:28 AM | Location : United States







Related Discussions:- Write script to clear the variables in the workspace, Assignment Help, Ask Question on Write script to clear the variables in the workspace, Get Answer, Expert's Help, Write script to clear the variables in the workspace Discussions

Write discussion on Write script to clear the variables in the workspace
Your posts are moderated
Related Questions
(a)  Create procedures for accessing the root, left subtree and right subtree, and also mutators for changing the root, left subtree and right subtree of an avl argument. (b) Wr

I need to finish my game project within two weeks using XNA. Would you guys can help me to finish it? Thank you

EF308 Assignment 2 Due: 3pm, 26 April 2012 Introduction This assignment is loosely based on Cheung et al. (2005) and Molodtsova and Papell (2009) and examines the out-of- sample pr

The following function calls supposedly write a single new-line character, but some are incorrect. Identify which calls don't work and explain why.     printf("%c", '\n');

Modularity, Abstraction, and Modelling Whether proving a theorem by creating up from lemmas to simple basic theorems to more accurate results, or designing a circuit by creati

Write a program that repeatedly prompts for and reads a positive integer value n and then calculates and displays the nth Fibonacci number


Components of .NET Framework 3.5 .NET Framework Conceptual Overview Presents the .NET Structure and its elements. Installing the .NET Framework Provides information about .NET Stru

The assignment has two parts: first you generate a simple application for a MID that operates independently of other MIDs. As a second part, the application is extended to keep so

This assignment will just focus on NookyKindle eBook orders.  That is, we'll be keeping track of the titles of eBooks and the number of orders for that particular eBook during a pa