Question: Instruction 1 - cat name, a string, randomly chosen from the name vector cat color, a string, randomly chosen from the color vector cat age,
Instruction 1 -
cat name, a string, randomly chosen from the name vector cat color, a string, randomly chosen from the color vector cat age, a random int between 0-11 cat gender, a random choice between 'fgh' or 'mnm'
The first piece of food they ate, a string, randomly chosen from the food vector. Yes, as soon as a goat is created (either through birth or through the farmer introducing another goat into the trip), they will eat something because they're goats. Your constructor should store this food string into the dynamic string array of items eaten. You will need a copy constructor for this assignment (if a goat gets cloned), using code to support that there will be dynamic memory in our class (the array of items that the goat has eaten). The rudimentary clarification of the standards of how the language coming about because of part (b) may be utilized to make a sentence structure analyser taking a token stream as information (by means of calls to work lex()) and giving as result an theoretical language structure tree relating to.
Note: Once the Dataframes are loaded please convert into temporary views so you can access directly using SQL, the view names should be "Salesview" and "Empview" respectively.
Consider the use of a monad for input-output. For the purposes of this question, take the IO monad as including two operations readint and writeint which respectively read integers from stdin and write integers to stdout. Give the types of these operators. [2 marks] (c) Assume MLreadint and MLwriteint are primitives with side effects for inputoutput and consider the ML expression add1 of type int: let val x = MLreadint() in MLwriteint(x+1); x end (i) Give an equivalent expression which uses the IO monad instead of side-effects, and state its type. [3 marks] (ii) Give a function run2diff which can be applied to your answer to part (c)(i). When so applied it should give a value in the IO monad which corresponds to ML code that runs add1 twice and returns the difference between the values read. [4 marks] (d) State what happens when attempting to compile and execute the following Java fragment (explaining the origin of any error messages or exceptions which might arise). Object n = new Integer(42), o = new String("Whoops"); Object [] x; Integer [] V = pos([H|T],[H|T]) :- H >= 0, pos(T,R). pos([H|H],S) :- H < 0, pos(T,R). 8 CST.2016.3.9 8 Software Engineering Discuss the contribution and the relative value of the following aspects of the modern development environment. Illustrate with examples from your group project, or from experience you gained working for a commercial software developer, or both. In each case, would you discard this feature if your employer let you, or insist on retaining it (even covertly) should your employer not value it? Explain your reasons. (a) Dividing a project into short development episodes or sprints. (b) Project progress visualisation tools such as PERT and GANTT charts. (c) Automated regression testing tools. (d) Source code management tools. (e) Scrumming
b.
Use 10009 for your items
Eaten dynamic array size (make sure to use a constant for this).
Use 10-80 as your random range for age when creating Goats that the farmer introduces into the trip (use constants).
Use age 40 when creating Goats by twin birth. Start with 31 goats in your trip (use a constant for this). Have your loop conduct at least 4 goatdates (use a constant for this).
Use lots of constants.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
