Vous êtes sur la page 1sur 3

Question 1:

Write both iterative and recursive functions that calculate the multiplication of
two numbers, with the constraint that the only mathematical operations that can
be performed in the function is addition and subtraction (ie, you are NOT
allowed to use the standard multiplication operation). The function may assume
that both numbers are greater or equal to 1 (ie non zero, and non negative).

Comment on the suitability of each solution for the specific problem, as well as
the suitability of iterative and recursive solutions in general, and the benefits that
each may have over the other in specific circumstances. In preparing this, you
may wish to try using large values, as well as find related information regarding
similar situations in C/VB environments.

Question 1 Part B

Write the test cases that you would use to test the functions that you have written in
Question 1 Part A, assuming that someone else had written them and you were a tester
assigned to test these particular functions

Question 2:

I want a procedure or function (or program, but a function or procedures


preferable), that takes 3 arguments as follows:

String, character, integer (number)

The function then returns the nth word (as determined by the integer)
surrounded by the character, that occurs in the string. It is easier to conceptualise
this if you assume the character is a space, then the function simply returns the
nth word. I know this is wordy, so here are some examples:

"The cat sat on the mat.", " ", 3 (space character, 3rd word)

This will return "on". Note that "The" is NOT the first word, as it is not
surrounded by spaces... it has a trailing space but no leading space.

"The cat sat on the mat.", " ", 1 (space character, 1st word)

Returns "cat"

"The cat sat on the mat.", " ", 10 (space character, 10th word)
This is an error, with undefined behaviour

"The cat sat on the mat.", "t", 1 ("t" character, 1st word)

Note that the T in The is uppercase, and therefore does not match the input
character the first t is therefore the t in cat, and the second t is the t in mat.
Therefore, the function returns all characters in between, ie, "sa".

"The cat sat on the mat.", "t", 2 ("t" character, 2nd word)

Returns " on ".

Now, I'd prefer a solution such as (or similar - this prototype is based on
WinRunner's TSL):

function MyFunc (InString As String, InChar As String, InNum As Integer)

...

meaning that you can easily pass any input to the function. However, so long as
the logic allows any input values, I don't really mind, so you could use constants
to define your parameters instead.

Note: I'd prefer this to be completed in C, VB, or Java. If it’s completed in TSL,
the split function cannot be used.

Question 3:

Write a short amount on what boundary testing is, why its useful, and how it can
apply in particular to automated testing.

Question 4:

What is the Quick Test Object Repository? What is it for, what are its advantages
and disadvantages? How different would Quick Test be without the Object
Repository (in answering this, please refer to the long term impact on the
application of automated testing to reaching project goals and deadlines).

Question 5:

What are custom functions and compiled modules? When are these beneficial?
What types of situation may warrant the use of them?
Question 6:

Describe the difference between an interpreted and a compiled language /


development environment.

Question 7:

From a purely technical viewpoint, why is Windows 2000 considered more


robust and secure than Windows 98?

Question 8:

What benefits would there be from using version control software to manage
source code?

Question 9:

When developing a Quick Test script, what process (or development steps) do
you personally use to go from a test requirement to a finished automated test
script? A high level overview is sufficient.

Question 10:

Create a VUser script that performs the following steps

1) Loads the google.com.au home page

2) Performs a search on a given topic (eg music)

3) Clicks the first link of the results

Perform the following enhancements:

* Parameterisation of the topic searched for

* Ensure that the link selected in step 3 is valid for any topic provided as data,
even if the data is updated in the future - ie, that the link is dynamically
correlated

* Any other enhancements that you think are necessary

Vous aimerez peut-être aussi