Average Case Flashcards
What is the intuition behind average case algorithms?
What is the definition of Expectation of variable T?
Find the expectation of T for the following:
Find the expactation of the following:
What is a Randomized Algorithm?
What is the randomized algorithm type: Las Vegas?
What is an example of this algorithm?
What is the randomised algorithm type; Monte Carlo?
What are the advantages/disadvantages of randomized algorithms in general?
What are the advantages/disadvantages of Las Vegas algorithms?
What are the advantages/disadvantages of Monte Carlo algorithms?
Why does it make more sense to think about expected time instead of worst-case time for Las Vegas algorithms?
In general, how is MySQL used in PHP?
What are JSPs?
For scripting languages in general, what benefits that does provide?
Java Server Pages (JSP):
Like PHP, JSPs consist of static elements (normally text and HTML) and JSP “Elements” that generate dynamic content.
JSPs provide:
- Language for developing text-based pages that describe how to process a request to create an HTML response
- A means of accessing server-side objects
- to provide a means of generating the dynamic content using information nt directly avail to the JPS
- A mechanism for extending the JSP language
- Which helps simplify repeated taskss and for future evolution of JSP technology
Which means:
- Separates the “user interface” (html) from content generation (script code)
- so we can change the page layout without changing code generating the dynamic content
- easier and faster development of web applications
- Decreased maintenance effort for web applications
- hence lower cost, more reliable
What tags enclose a Java expression that is to be evaluated for JPS?
The time is
JSP support the embedding of short sequences of Java code, what do we call them?
What tags are used ot do this?
Called “Scriptlets”, these are embedded in HTML pages
Done with the tags (not that the ‘=’ sign is missing)
The time is:
NOTE: The declaration persists across tags