Well, you gotta do what you're comfortable with, of course. Still, if your food is half as good as it sounds all the time, paired with you growing your own vegetable garden in the backyard, you have to admit, you have a knack for it. And from the look of it, definitely a passion for it.
Well yeah it started when I was young, I've been cooking since I was 8.. I like to cook, it's fun to me. I really like when I make something that someone finds amazing, that certain satisfaction you can only get from a well prepared meal (what fast food could never offer) I like giving people that.
If I went to school, then I think I could be on that level..
Maybe someday I will go. I know I can't afford to even hope and dream right now (I'm prone to disappointment induced depression) but my ultimate life goal, the one thing that if I achieved I'd be satisfied, is owning my own SUCCESSFUL restaurant. The sad reality is so many go after this dream and fail miserably.
Algorithm A runs in polynomial time if there is a polynomial p such that for every x, the call A(x) halts in at mostp(|x|) steps.
2. How does one prove, straightforwardly, that an algorithm runs in polynomial time?
One can straightforwardly prove that an algorithm runs in polynomial time by counting the largest possible number of operations executed for an input of unknown size n. If this formula is a polynomial, then the algorithm runs in polynomial time.
3. What is the largest possible number of operations that can be executed in the following algorithm, on an input stack S of size n? Count the number of calls to the operators :=, push, top, pop, not, is_empty, =, and return.
algorithm Palindrome(stack<int> S)
// returns True if S is a palindrome and False otherwise, destroying its input in the process
begin
// create two reversed copies of the reverse of S, in T1 and T2, while destroying S
stack<int> T1 := empty
stack<int> T2 := empty
while not is_empty(S):
push(top(S),T1)
push(top(S),T2)
pop(S)
// now destroy T1 and restore S
while not is_empty(T1):
push(top(T1),S))
pop(T1)
// Now S is back to its original value, and T2 is the reverse of S.
// Check if S = T2
while not is_empty(S):
if not top(S)= top(T2): return False
return True
end
Solution:
Let n be the length of S. The first 2 assignments always happen. Each iteration of the loop body executes five instructions for a total of 5n inside the loop body. Additionally the expressopm not is_empty(S) in the loop guard is executed n+1 times, for a total of 2n+2 function calls (counting both not's and is_empty's). Similarly, the next loop executes 3n instructions in the loop body and 2n+2 function calls in the loop guard. In the worst case, the final loop executes n times, each doing a not, two tops, and a comparison (but NOT a return), for a total of 4n function calls in the loop body and 2n+2 in the loop guard. Finally we have 1 return instruction. The total then is
2+(5n+2n+2) + (3n+2n+2) + (4n+2n+2) + 1
for a total of 18n+9 instructions and function calls.
4. Define class P
Predicate R is in class P if there is a polynomial time algorithm A that decides R.
5. What is the point of studying class P?
Class P is a mathematical formulation of the notion of the intuitive notion of tractability, in the same way that general recursiveness is a mathematical forumlation of the intuitive notion of computability. (Tractable means, roughly speaking, computable in a reasonable amount of time).
6 How does one prove, straightforwardly, that a predicate is in class P?
The straightforward way to prove that a predicate is in class P is go implement it by a polynomial time algorithm.
7. Define class NP
Predicate p is in class NP if there is a polynomial-time algorithm A and a polynomial q such that (1) if p(x) is true then there is some string y of length less than or equal to q(|x|) such that A(x,y) returns true, and (2) if p(x) is false then there is no such string.
8. Give the alternative characterication of class NP in terms of nondetermistic algorithms:
Theorem: A predicate p is in class NP if there is a nondeterministic algorithm A and a polynomial q such that (1) whenever p(x) is true, A(x) has an execution path that returns true in q(|x|) or fewer steps, and (2) A(x) never has a path that returns true when p(x) is false.
9. Prove that the predicate SAT is in class NP using the theorem stated in question 8.
11. State the definitions of NP-hard and NP-complete.
12. State the Cooke-Levin Theorem.
13. Name five of of Karp's 21 NP-complete problem, and describe three of those five. Write your descriptions so that anyone who has had a course in discrete math can understand it precisely.
14. Describe a basic method to show that a predicate is undecidable.
Solution: To show that p is undecidable, implement a solution to a problem that is already known to be undecidable (e.g., the halting problem) that calls p as a helper, and in which all other components can be implemented.
15. Describe the basic method to show that a a problem is NP-complete.
Solution: To show that given problem is NP-complete, one can do the following two steps:
Show that your problem is in NP by writing an algorithm A as described in the definition of NP-completeness (or in the alternative characterization)
Write a polynomial time pseudocode algorithm that decides a known NP-complete problem (such as SAT), all of whose helper functions are in class P except for your problem.
Note this is conceptually similar to the technique for showing that a problem is undecidable.
16. What is the practical significance of showing that a predicate is in class NP-complete?
Answer: Practically speaking, you should not expect to implement a polynomial time algorithm for it -- or, even more intuitively, an algorithm that runs for large inputs in a reasonable amount of time.
17. Give the signatures of NP-complete and polynomial time
Solution:
NP-complete: predicate -> Bool
polynomial time : algorithm -> Bool
You could try going for a truck. They're cheaper and you can generate a lot more sales if you know where to go and when. I say they're cheaper, but they are still pretty expensive. Of course, the difference between a truck and a full blown restaurant is staggering. Still, something to think about. I'd also like to say that I'd be afraid of going to school for something you love, in case repetition and grading and regulation might sour the experience for you, but I don't know if that's honestly true. Too bad Ina's not around. I'd bet he could tell you firsthand. Still, that dream does sound awesome. Perhaps someday, if things work out. I just hope they do.
Oh yeah I wouldn't just jump into buying a restaurant. At the absolute minimum I'll of have to of already spent ~15 or so years working in a restaurant. I wouldn't dare attempt it without first having a lot of first hand experience under my belt. If I ever did open one, I'll of been planning it for a long, long time before hand.
As for where to go in a food truck.. I live like an hour from Downtown Houston... Where there is perpetually ongoing construction. Plus pretty close to some of the biggest plants in the US. I'm not sure if they do allow food trucks in there, but if they do, I basically have no lack of clientele.
OMG <_< Fresh tamales are amazing. I've only ever had that hormel crap that comes in a can... It's one of those things where you take one bite and then you want to follow it with 100 more.
Algorithm A runs in polynomial time if there is a polynomial p such that for every x, the call A(x) halts in at mostp(|x|) steps.
2. How does one prove, straightforwardly, that an algorithm runs in polynomial time?
One can straightforwardly prove that an algorithm runs in polynomial time by counting the largest possible number of operations executed for an input of unknown size n. If this formula is a polynomial, then the algorithm runs in polynomial time.
3. What is the largest possible number of operations that can be executed in the following algorithm, on an input stack S of size n? Count the number of calls to the operators :=, push, top, pop, not, is_empty, =, and return.
algorithm Palindrome(stack<int> S)
// returns True if S is a palindrome and False otherwise, destroying its input in the process
begin
// create two reversed copies of the reverse of S, in T1 and T2, while destroying S
stack<int> T1 := empty
stack<int> T2 := empty
while not is_empty(S):
push(top(S),T1)
push(top(S),T2)
pop(S)
// now destroy T1 and restore S
while not is_empty(T1):
push(top(T1),S))
pop(T1)
// Now S is back to its original value, and T2 is the reverse of S.
// Check if S = T2
while not is_empty(S):
if not top(S)= top(T2): return False
return True
end
Solution:
Let n be the length of S. The first 2 assignments always happen. Each iteration of the loop body executes five instructions for a total of 5n inside the loop body. Additionally the expressopm not is_empty(S) in the loop guard is executed n+1 times, for a total of 2n+2 function calls (counting both not's and is_empty's). Similarly, the next loop executes 3n instructions in the loop body and 2n+2 function calls in the loop guard. In the worst case, the final loop executes n times, each doing a not, two tops, and a comparison (but NOT a return), for a total of 4n function calls in the loop body and 2n+2 in the loop guard. Finally we have 1 return instruction. The total then is
2+(5n+2n+2) + (3n+2n+2) + (4n+2n+2) + 1
for a total of 18n+9 instructions and function calls.
4. Define class P
Predicate R is in class P if there is a polynomial time algorithm A that decides R.
5. What is the point of studying class P?
Class P is a mathematical formulation of the notion of the intuitive notion of tractability, in the same way that general recursiveness is a mathematical forumlation of the intuitive notion of computability. (Tractable means, roughly speaking, computable in a reasonable amount of time).
6 How does one prove, straightforwardly, that a predicate is in class P?
The straightforward way to prove that a predicate is in class P is go implement it by a polynomial time algorithm.
7. Define class NP
Predicate p is in class NP if there is a polynomial-time algorithm A and a polynomial q such that (1) if p(x) is true then there is some string y of length less than or equal to q(|x|) such that A(x,y) returns true, and (2) if p(x) is false then there is no such string.
8. Give the alternative characterication of class NP in terms of nondetermistic algorithms:
Theorem: A predicate p is in class NP if there is a nondeterministic algorithm A and a polynomial q such that (1) whenever p(x) is true, A(x) has an execution path that returns true in q(|x|) or fewer steps, and (2) A(x) never has a path that returns true when p(x) is false.
9. Prove that the predicate SAT is in class NP using the theorem stated in question 8.
11. State the definitions of NP-hard and NP-complete.
12. State the Cooke-Levin Theorem.
13. Name five of of Karp's 21 NP-complete problem, and describe three of those five. Write your descriptions so that anyone who has had a course in discrete math can understand it precisely.
14. Describe a basic method to show that a predicate is undecidable.
Solution: To show that p is undecidable, implement a solution to a problem that is already known to be undecidable (e.g., the halting problem) that calls p as a helper, and in which all other components can be implemented.
15. Describe the basic method to show that a a problem is NP-complete.
Solution: To show that given problem is NP-complete, one can do the following two steps:
Show that your problem is in NP by writing an algorithm A as described in the definition of NP-completeness (or in the alternative characterization)
Write a polynomial time pseudocode algorithm that decides a known NP-complete problem (such as SAT), all of whose helper functions are in class P except for your problem.
Note this is conceptually similar to the technique for showing that a problem is undecidable.
16. What is the practical significance of showing that a predicate is in class NP-complete?
Answer: Practically speaking, you should not expect to implement a polynomial time algorithm for it -- or, even more intuitively, an algorithm that runs for large inputs in a reasonable amount of time.
17. Give the signatures of NP-complete and polynomial time
Solution:
NP-complete: predicate -> Bool
polynomial time : algorithm -> Bool
I saw numbers and died.
And the tamale sellers actually sell them outside trucks. Like I'ma buy a tamale from there. I don't know where your hands have been!
Joined a guild on a pvp game, first rule they told me, don't farm fellow guildies. 99% of the people in the guild turn out to be people I farm everyday. fml. /lonewolf
Weird dream tonight, I remember little of it and I'll write it just so I don't forget it..
First I was at like a big concert where I remained till the end when there were like 20-30 people left, so I sat in a corner and pulled out a book of swedish grammar(??)and tried to learn it also while teaching it to a DOG(yes I tried to teach swedish to a dog). So moving on I was in a very big house with a swimming pool and stuff and it was packed with people from all over the world, men and women and everyone was forced to wear clothes of the colour of their flag, until I rebeled(*** green and red, I don't like it)so we all started stripping and switching clothes...it became kinda sexy too. Then after this weird party...a certain person came to pick me up to take me home. On the drive home I was scared that we could meet my father so I was hurrying him to go faster, but he was fascinated by the view of an italian pizzeria and wanted to stop there to eat at all costs. So I was all tense scared that my dad could come out any moment in that place, when suddenly instead my bestie appears. I get up to go say hi to her but as I'm trying to hug her a random dude gets in the way and hugs me instead introducing himself, while I was like 'who the *** is this?'
And so the dream ended.
This is a thread that I found on another website I post at. It can be really really interesting. I thought it deserved a place here.
Post your random thoughts for the day here, or anything else that intrigues you.
For starters, is it possible to give constructive critism to someone who doesn't have a neck? I totally just walked by a girl who didn't. Someone isn't getting a necklace for Valentines day!
And who decided black and white can't be colors? I want to say a racist. I really do.