Ok, I think I get it now. I'm pretty sure I got the questions relating to it right because I had a hunch what the methods were supposed to do, it just bothered me that I didn't know how it worked.
I just took my final for Data Structures and there was a question on it dealing with linked lists. A part of the question really threw me off. It looked something like this:
public class Node
{
int contents;
Node next;
}
public class LinkedList
{
Node head, tail...
I have been given a practice exam from my professor (http://www.cs.pitt.edu/~aronis/cs0445/miscellaneous/cs445-spring-2007-test-3.pdf ) along with an answer sheet (http://www.cs.pitt.edu/~aronis/cs0445/miscellaneous/cs445-spring-2007-test-3-answers.txt ) and there are a good number of questions...
OK, I see now. Thank you. Here's another problem I'm stuck on:
A department contains 10 men and 15 women. How many ways are there to form a committee with six members if it must have more women than men?
What I figure out so far is that this would be a combination, not a permutation. If...
How many permutations of the letters ABCDEFGH contain the string ABC?
This is an example problem in my book, and the answer is 6! = 720. Could someone please explain to me the reasoning behind this (my book does a poor job explaining)? And would this reasoning apply if the string to be...
Homework Statement
1. How many strings of eight English letters are there if no letter can be repeated?
2. How many strings of eight English letters are there if X is the first letter and no letter can be repeated?
3. How many strings of three decimal digits do not contain the same digit...
Homework Statement
Show that if a, b, c, and d are integers such that a | c and b | d, then ab | cd.
Let m be a positive integer. Show that a mod m = b mod m if a ≡ b(mod m)
Homework Equations
| means "divides," so a | b means "a divides b" or "b can be divided by a"
mod gets the...
Homework Statement
I have to find all of the points of intersection of the curves...
r2 = sin(2θ)
r2 = cos(2θ)
The Attempt at a Solution
sin(2θ) = cos(2θ)
2sinθcosθ = cos2θ - sin2θ
2sinθcosθ - cos2θ = -sin2θ
cosθ(2sinθ - cosθ) = -sin2θ
This is where I'm having a problem, I'm...
Thanks a lot! In that case...
sin(θ) = 2sin(θ)cos(θ)
1 = 2cos(θ)
cos(θ) = 1/2
θ = π/3
That should help me get the rest of the problem, thanks again! =]
Homework Statement
I have to find the area of the region that lies inside the curves:
r = sin(θ)
r = sin(2θ)
The Attempt at a Solution
I'm assuming the first step would be to find the points of intersection so I know WHERE to integrate from/to, so I set the equations equal to each...
Homework Statement
I barely even know where to begin with this proof:
Show that the product of two of the numbers 651000 - 82001 + 3177, 791212 - 92399 + 22001 and 244493 - 58192 + 71777 is nonnegative.
I also have to state if it is constructive or nonconstructive, and I'm not supposed to...
Homework Statement
If 6 J of work is needed to stretch a spring from 10 cm to 12 cm and another 10 J is needed to stretch it from 12 cm to 14 cm, what is the natural length of the spring?
Homework Equations
Spring constant - f(x) = kx
\intab f(x)dx where a,b are initial and ending...