Questions
b. The seven balance-related audit objectives related to accounts payables include: 1. Accounts payable in the...

b. The seven balance-related audit objectives related to accounts payables include:

1. Accounts payable in the accounts payable list agree with related master file, and the total added is correct and agrees with the general ledger (detail tie-in).

2. Accounts payable in the ac-counts payable list exist (existence).

3. Existing accounts payable are included in the accounts payable list (completeness).

4. Accounts payable in the ac-counts payable list are accurate (accuracy).

5. Accounts payable in the ac-counts payable list are correctly classified (classification).

6. Transactions in the acquisition and payment cycle are recorded in the proper period (cutoff).

7. The company has an obligation to pay the liabilities included in accounts payable (obligations).

Required

Select any Five (5) out of the above seven (7) balance-related audit objectives, suggest a substantive test of details of balances procedures used. 10 marks

Total 25 marks

In: Accounting

Inheritance - Polymorphism One advantage of using subclasses is the ability to use polymorphism. The idea...

Inheritance - Polymorphism

One advantage of using subclasses is the ability to use polymorphism.

The idea behind polymorphism is that several different types of objects can have the same methods, and be treated in the same way.

For example, have a look at the code we’ve included for this problem. We’ve defined Shape as an abstract base class. It doesn’t provide any functionality by itself, but it does supply an interface (in the form of .area() and .vertices() methods) which are meaningful for any type of 2D Shape.

The total_area function makes use of this to calculate the area of any kind of Shape. We’ve provided an example of this with two Square instances.

We want you to write RightAngledTriangle and Rectangle classes which implement this interface.

The constructor for RightAngledTriangle accepts one argument, vertices, being a list of the points of the triangle relative to its origin. The first vertex will be at the right angle.

The constructor for Rectangle accepts width and height.

class Shape():
"""
A representation of a shape.

"""
def __init__(self, origin=(0, 0)):
"""Construct a shape object
  
Parameters:
origin(tuple<int, int>): origin of the shape
  
"""

self.origin = origin

def area(self):
"""
(int) Return the area of the shape.

"""
raise NotImplementedError()

def vertices(self):
"""
Return the vertices of the shape.

Return:
list<tuple<int, int>>: The vertices of the shape, as a list of tuples
representing two dimensional points.
This list may be returned in any order.
  
"""
raise NotImplementedError()


class Square(Shape):
"""A Square object"""
def __init__(self, side_length, origin=(0, 0)):
"""
Construct a square object
  
Parameters:
side_length (int): Length of the sides of the square
origin (tuple<int, int>): Coordinate of topleft corner of square
  
"""
super().__init__(origin=origin)

self.side_length = side_length

def area(self):
"""
(int) Return the area of the shape.
  
"""
return self.side_length * self.side_length

def vertices(self):
"""
Return the vertices of the shape.

Return:
list<tuple<int, int>>: The vertices of the shape, as a list of tuples
representing two dimensional points.
This list may be returned in any order.
  
"""
x, y = self.origin

return [
(x, y),
(x, y + self.side_length),
(x + self.side_length, y + self.side_length),
(x + self.side_length, y),
]


def total_area(shapes):
"""
Return the total area of the given list of shapes.

Parameters:
shapes (list<Shape>): The list of shapes to sum the area for.

Return:
int: The total area of the list of shapes, being the sum of the area of
each individual shape.

"""
area = 0.

for shape in shapes:
area += shape.area()

return area


def outer_bounds(shapes):
"""
Return the outer bounds of the given list of shapes.

Parameters:
shapes (list<Shape>): The list of shapes to return the outer bounds for.

Return:
tuple<tuple<int, int>, tuple<int, int>>:

The first element of the tuple is the top-left corner of a rectangle
which could enclose every shape in the given list.
The second element of the tuple is the bottom-right corner of that same
rectangle.

The top-left corner of the rectangle will be, at minimum, (0, 0).

"""
vertices = []

for shape in shapes:
for vertex in shape.vertices():
vertices.append(vertex)

top_left_x = 0
top_left_y = 0
bottom_right_x = 0
bottom_right_y = 0

for x, y in vertices:
if x < top_left_x:
top_left_x = x
elif x > bottom_right_x:
bottom_right_x = x

if y < top_left_y:
top_left_y = y
elif y > bottom_right_y:
bottom_right_y = y

return (top_left_x, top_left_y), (bottom_right_x, bottom_right_y)


# example usage
# note that total_area doesn't know nor care that we used instances of Square
shapes = [Square(2), Square(4, origin=(2, 2))]
area = total_area(shapes)

In: Computer Science

Programming Activity 7 - Guidance ================================= This assignment uses a built-in Python dictionary. It does not...

Programming Activity 7 - Guidance =================================

This assignment uses a built-in Python dictionary. It does not use a dictionary implementation from the textbook collections framework. It does not require any imports/files from the textbook collections framework. This week's "examplePythonDictionary.py" example uses a built-in Python dictionary. Note that the mode() function begins by creating an empty Python dictionary. You must use this dictionary in the following parts.

Part 1 ------ In this part you will add entries to the dictionary. Use a "for" loop to iterate through the values in the data list. For each value, use it as a dictionary key to see if it is already in the dictionary. If it is already in the dictionary, add one to that dictionary entries value. Each dictionary value contains the number of times that value occurs in the data. You reference the current value for a key via dictionary[key]. If it is not in the dictionary, add it by assigning an entry for it with a value of 1.

Part 2 ------ Python has a built-in max() function that finds the maximum in any iterable object. Use max() on the list of dictionary values to obtain the maximum number of times a value occurs. Assign this to a variable called maxTimes. You will make use of maxTimes in part 3.

Part 3 ------ Note that this part begins by creating an empty modes list. Use a "for" loop to loop through the dictionary keys. The default "for" iterator for a Python dictionary iterates through its keys. For each key, see if its associated dictionary value is equal to maxTimes. If it is equal, append that key to the modes list.

Part 4 ------ If no item in the data set is repeated, then your modes list at this point will be the same as your starting data list. However, this case actually should mean there is no mode. Actually, every item is a mode with a frequency of 1. But, we want to return an empty modes list for this case. If the modes list and the data list have the same length, reset modes to an empty list. Note that modes is already being returned at the end of the function.

=============================================================================================================================

useDictionary.py

# This program uses a Python dictionary to find the mode(s) of a data set.

# The mode of a data set is its most frequently occurring value.
# A data set may have more than one mode.
# Examples:
# mode of [1,2,3,4,5,6,7] is none
# mode of [1,2,3,4,5,6,7,7] is 7
# modes of [1,2,2,2,3,3,4,5,6,7,7,7] are 2 and 7

# Replace any "<your code>" comments with your own code statement(s)
# to accomplish the specified task.
# Do not change any other code.

# This function returns a list containing the mode or modes of the data set.
# Input:
# data - a list of data values.
# Output:
# returns a list with the value or values that are the mode of data.
# If there is no mode, the returned list is empty.
def mode(data):
dictionary = {}

# Part 1:
# Update dictionary so that each dictionary key is a value in data and
# each dictionary value is the correspinding number of times that value occurs:
# <your code>

# Part 2:
# Find the maximum of the dictionary values:
# <your code>

# Part 3:
# Create a list of the keys that have the maximum value:
modes = []
# <your code>

# Part 4:
# If no item occurs more than the others, then there is no mode:
# <your code>

return modes

data1 = [1,2,3,4,5,6,7]
print(data1)
print("mode:", mode(data1))
print()

data2 = [1,2,3,4,5,6,7,7]
print(data2)
print("mode:", mode(data2))
print()

data3 = [1,2,2,2,3,3,4,5,6,7,7,7]
print(data3)
print("mode:", mode(data3))
print()

data4 = ["blue", "red", "green", "blue", "orange", "yellow", "green"]
print(data4)
print("mode:", mode(data4))
print()

In: Computer Science

list and explain the 8 symptoms of groupthink?

list and explain the 8 symptoms of groupthink?

In: Statistics and Probability

List and define three sources of stress

List and define three sources of stress

In: Nursing

Please List the milliequivalent values of the following

 

Please List the milliequivalent values of the following

100 Na+ ions equals __________ milliequivalents

52 CI- ions equals _________ milliequivalents

312 Ca++ ions equals __________ milliequivalents

6 K± ions equals ___________ milliequivalents

In: Biology

List the functions of testosterone and describe them

List the functions of testosterone and describe them

In: Nursing

list the various elements of financial modeling.

list the various elements of financial modeling.

In: Finance

List the determinants that shift the supply curve.?

List the determinants that shift the supply curve.?

In: Economics

List and explain the steps in hypothesis testing

List and explain the steps in hypothesis testing

In: Statistics and Probability