 As the wacko billionaire who made his fortune off the backs of the Moonie cult (otherwise known as the Unification Church), Moon has established his niche in the world as the Korean version of L. Ron Hubbard.Over the years, Moon's gargantuan wealth and legions of worshippers have evidently corroded away any sense of propriety or self-restraint he might have once possessed, leaving only a megalomaniac and his vast financial and human resources. As evidence, consider the day in April 2002 when he received the latest in a long series of earthshattering religious visions. This one was especially noteworthy. In it, Moon learned that he had been selected as "the Savior, Messiah and King of Kings of all of humanity" by God. Also on the selection committee: Jesus Christ, Mohammed, and Buddha (in addition to several others, including the godless Communists Marx and Stalin for some mysterious reason). Anyway, that's how Moon described it in his full-page newspaper ad, which ran in papers all across the U.S. (including the Los Angeles Times). It was a $720,000 print run, but it was worth every penny. Finally middle America would get the word and rally behind their messiah. Except it was a bit of a reach. Moon's captive congregation is accustomed to his indefatigable hubris, but the general public who have yet to send their mind through the laundry just find it repugnant. But he can't help it. Moon has been claiming for decades (like The Beatles before him) that he is bigger than Christ. In a 1990 sermon, he reiterated this belief (note that Moon always addresses himself in the third person, usually as "Father"):
"Jesus never achieved a thousandth of what Father has done. In his two years and eight months of public ministry, [Jesus] didn't even establish the national foundation. Now, Father has established a foundation of worldwide power that is unprecedented in history."Moon has a bad habit of comparing himself favorably to his predecessor, proclaiming that he will succeed where Jesus has failed, and so on. This kind of material kills with the home crowd, but it doesn't really do so great on the road. But apparently this is irrelevant, since Moon seems to have become utterly oblivious to the shocked reactions of his public audiences. Case in point: an April 2001 appearance at a Methodist church in Las Vegas. It was just another typical sermon by Reverend Moon. There were about 600 people in the congregation when the sermon began. But for some reason, people kept walking out, well before he got on a roll about schlongs:
"The head of the love organ is shaped exactly like a poisonous rattlesnake. And just like a rattlesnake, it's always looking for a hole." Oh yes, there was more. He went on to explain that 70% of all divorces result from the wife's inappropriate feelings of entitlement toward her husband's genitals. As Moon explained it, a man's "love organ" can only serve its master, and the spouse just needs to get used to it. He told the audience that these women, along with childless couples and homosexuals, are destroying the fabric of society. Offended churchgoers left in droves; some of them even heckled him on their way out. And this was by no means an isolated incident. He's been spouting that snake-genitalia lunacy for years and years. In April 1996, Moon preached:
"The Bible refers to the origin of free sex by using the image of a snake.   If you think of fallen love action in these terms you feel disgusted and so you should. It is poison to humanity." In November of that same year, he was in Buenos Aires to celebrate the launch of his newest Spanish-language newspaper. At the ceremony (attended by guest speaker and former President George HW Bush for a reported fee of $100,000), Moon passed along this revolutionary insight:
Why would anybody (who isn't brainwashed or getting paid) sit through an entire speech by this screwball? Ever since 1954, Moon has made no secret of his nutball theology:
In a Moonie marriage, the choice of a partner is handled for you. Church elders make the seemingly-random selections by pairing up photos of prospective brides and grooms. Maybe they shuffle Polaroids like a deck of cards. Sometimes the lucky couples wind up with a common spoken language. Sometimes not. They meet for the first time during the week leading up to the wedding day, often on the day of the ceremony itself. The event is so big that it has to be held in a sports arena or stadium, complete with a closed-circuit video feed on the Jumbotron. Because of these antics and his blasphemous theology, you might expect that Moon would be shunned by respected Christian leaders. Which he is. For instance, Jerry Falwell told Esquire magazine in 1978: "Reverend Sun Myung Moon is like the plague: he exploits boys and girls, and he should be exported. [sic]" This negative general attitude poses a significant problem for the Unification Church. Its goal is the absorption of every national government and competing religious faith. Which is a tall order, considering the horrible reputation the church has earned over the years. But Moon is nothing if not determined.
"The democratic world has hated Reverend Moon until now, but from now on it will like the Reverend Moon. The time has already come when America will start to like Reverend Moon." Moon's chosen tactic, which has been highly effective, is to purchase his legitimacy outright. In addition to United Press International (UPI), Moon is the owner of the Washington Times, a conservative newspaper devoted to right-wing causes. Every operating year, the Times loses tens of millions of dollars, but profitability has never been a priority. Its intended purpose was made clear when, during Watergate, the paper ran an endless stream of pro-Nixon editorials urging the American people to forgive and forget. Ever since then, Moon has made substantial inroads to the Republican party by parlaying access to his media outlets and exorbitant cash contributions.  The NFF's mission in life was to raise private donations for the Contras, in the eventuality that Congress cut off funding. Also recall that former President George HW Bush was paid six figures to attend a 1996 ceremony in Buenos Aires. At the podium, Bush gushed:
"I want to salute Reverend Moon, who is the founder of the Washington Times, and of the new paper here." Not to mention mainstream church leaders, like our old friend Jerry Falwell. The man who called for Moon's "exportation" in 1978 was singing his praises years later. Falwell changed his tune after one of Moon's front organizations handed Liberty University $3.5 million and otherwise forgave tens of millions in debts so he could bail out his college in 1994. Later, Falwell reciprocated by appearing at various Unification Church events and called upon President Ronald Reagan to pardon Moon's felony conviction for tax evasion. Oh, that. Well, it turns out that the messiah didn't want to pay his taxes. So he underreported his income by omitting $162,000 and hoped that either the Internal Revenue Service wouldn't notice, or his high-placed friends in the government would squelch any investigation. But the IRS did, and his friends didn't. Moon was convicted in 1982. He fought his conviction all the way to the Supreme Court and lost, after which he announced that God evidently wanted him to go to prison. In 1984 he finally submitted to God's will and spent the next 13 months in the clink. It's all part of the divine plan. As Moon himself might say: You just gotta trust Father on this one.
timeline
|


This example shows you how to use modalEasterEgg.
This is the version which use the pure JavaScript.
modalEasterEgg uses both mouse and keyboard events. In the current page with your
mouse go over this gray

 and press the "
i" from your keyboard; Now you can see the secret message.
All you need to do is:
- Change the settings in modalEasterEgg.json:
- theElement → The ID of the HTML element for the mouse event.
- theMessage → The text of your message (You can add HTML tags too).
- theCharacter → The character for keyboard event.
- messageStyle → The CSS style for your message.
- modalBlock → This is the modal block. Don't change it.
- Add modalEasterEgg.min.js and modalEasterEgg.min.css to your codes.
- Add

 to the body of your webpages.
- Put the modalEasterEgg.json file in the proper address (default is the same folder of your webpages).


The drunk fist website
So, The name drunk fist comes from the name of a test account I setup to test the Facebook Developer API toolkit. In layman’s terms, it was an account I setup for a work project years ago.
The name ‘Drunk fist’ came from an old Kung Fu movie I saw and I liked the name and I decided to re-use it to start to blog about all things diet, nutrition, health and fitness. Basically anything interesting I find that’s not code related and too long to just share on social media.
I am at the time of writing this blog post a 41-year-old man from Oxfordshire in the UK and have transitioned from being a full-time sedentary Software Developer and DevOps guy into being a full-time carer for my elderly mother and my brother who had a stroke a while back.
Part of this progress has included my new diet, weight loss and interest in Boxing, Muay Thai, Brazillian Jui Jitsu, MMA and Kettlebells and generally just trying to navigate my middle years while being as fit and healthy in mind and body as possible.
Well, I have a couple of websites and blogs and the main one is hosted on blogger and has years of content and lives at http://www.solrevdev.com/
It is very technical in nature and has been live for quite a long time and eventually I will migrate that away from the ageing blogger eco-system to a Github-hosted blog run from Jekyll as is this one is.
In fact, the boilerplate site is ready for the content to be imported to this location http://solrevdev.github.io/
So, as well as programming, system administration, DevOps and all things technical my relatively new pursuits are health and fitness and I have various social media accounts that are plotting my progress in Boxing, Muay Thai, Brazillian Jui Jitsu, MMA (mixed martial arts) and Kettlebell training.
While social media such as Facebook, Twitter and Instagram are great for short form content I wanted a website and blog where longer form posts about my interests and progress could live and well, this is it.


{%extends "registration/base.html"%} {% load bootstrap3 %} {% block content %}
Password or Username is incorrect
Forgot Password?
Don't have an account? Sign Up
-- OR --


TacticsMore Basic Tactics
- how to use auxiliary lemmas in both "forward-style" and "backward-style" proofs;
- how to reason about data constructors (in particular, how to use the fact that they are injective and disjoint);
- how to strengthen an induction hypothesis (and when such strengthening is required); and
- more details on how to reason by case analysis.
Set Warnings "-notation-overridden,-parsing".
Require Export Poly.
The apply Tactic
Theorem silly1 : ∀ (n m o p : nat),
n = m →
[n;o] = [n;p] →
[n;o] = [m;p].
Proof.
intros n m o p eq1 eq2.
rewrite <- eq1.
Here, we could finish with "rewrite → eq2. reflexivity." as we
have done several times before. We can achieve the same effect in
a single step by using the apply tactic instead:
apply eq2. Qed.
The apply tactic also works with conditional hypotheses
and lemmas: if the statement being applied is an implication, then
the premises of this implication will be added to the list of
subgoals needing to be proved.
Theorem silly2 : ∀ (n m o p : nat),
n = m →
(∀ (q r : nat), q = r → [q;o] = [r;p]) →
[n;o] = [m;p].
Proof.
intros n m o p eq1 eq2.
apply eq2. apply eq1. Qed.
You may find it instructive to experiment with this proof
and see if there is a way to complete it using just rewrite
instead of apply.
Typically, when we use apply H, the statement H will
begin with a ∀ that binds some universal variables. When
Coq matches the current goal against the conclusion of H, it
will try to find appropriate values for these variables. For
example, when we do apply eq2 in the following proof, the
universal variable q in eq2 gets instantiated with n and r
gets instantiated with m.
Theorem silly2a : ∀ (n m : nat),
(n,n) = (m,m) →
(∀ (q r : nat), (q,q) = (r,r) → [q] = [r]) →
[n] = [m].
Proof.
intros n m eq1 eq2.
apply eq2. apply eq1. Qed.
Theorem silly_ex :
(∀ n, evenb n = true → oddb (S n) = true) →
evenb 3 = true →
oddb 4 = true.
Proof.
(* FILL IN HERE *) Admitted.
Theorem silly3_firsttry : ∀ (n : nat),
true = beq_nat n 5 →
beq_nat (S (S n)) 7 = true.
Proof.
intros n H.
simpl.
Here we cannot use apply directly, but we can use the symmetry
tactic, which switches the left and right sides of an equality in
the goal.
symmetry.
simpl. (* (This simpl is optional, since apply will perform
simplification first, if needed.) *)
apply H. Qed.
Exercise: 3 stars (apply_exercise1)
(Hint: You can use apply with previously defined lemmas, not just hypotheses in the context. Remember that Search is your friend.)Theorem rev_exercise1 : ∀ (l l' : list nat),
l = rev l' →
l' = rev l.
Proof.
(* FILL IN HERE *) Admitted.
Exercise: 1 star, optionalM (apply_rewrite)
Briefly explain the difference between the tactics apply and rewrite. What are the situations where both can usefully be applied?☐
The apply ... with ... Tactic
Example trans_eq_example : ∀ (a b c d e f : nat),
[a;b] = [c;d] →
[c;d] = [e;f] →
[a;b] = [e;f].
Proof.
intros a b c d e f eq1 eq2.
rewrite → eq1. rewrite → eq2. reflexivity. Qed.
Since this is a common pattern, we might like to pull it out
as a lemma recording, once and for all, the fact that equality is
transitive.
Theorem trans_eq : ∀ (X:Type) (n m o : X),
n = m → m = o → n = o.
Proof.
intros X n m o eq1 eq2. rewrite → eq1. rewrite → eq2.
reflexivity. Qed.
Now, we should be able to use trans_eq to prove the above
example. However, to do this we need a slight refinement of the
apply tactic.
Example trans_eq_example' : ∀ (a b c d e f : nat),
[a;b] = [c;d] →
[c;d] = [e;f] →
[a;b] = [e;f].
Proof.
intros a b c d e f eq1 eq2.
If we simply tell Coq apply trans_eq at this point, it can
tell (by matching the goal against the conclusion of the lemma)
that it should instantiate X with [nat], n with [a,b], and
o with [e,f]. However, the matching process doesn't determine
an instantiation for m: we have to supply one explicitly by
adding with (m:=[c,d]) to the invocation of apply.
apply trans_eq with (m:=[c;d]).
apply eq1. apply eq2. Qed.
Actually, we usually don't have to include the name m in
the with clause; Coq is often smart enough to figure out which
instantiation we're giving. We could instead write: apply
trans_eq with [c;d].
Exercise: 3 stars, optional (apply_with_exercise)
Example trans_eq_exercise : ∀ (n m o p : nat),
m = (minustwo o) →
(n + p) = m →
(n + p) = (minustwo o).
Proof.
(* FILL IN HERE *) Admitted.
☐
m = (minustwo o) →
(n + p) = m →
(n + p) = (minustwo o).
Proof.
(* FILL IN HERE *) Admitted.
The inversion Tactic
Inductive nat : Type :=
| O : nat
| S : nat → nat.
It is obvious from this definition that every number has one of
two forms: either it is the constructor O or it is built by
applying the constructor S to another number. But there is more
here than meets the eye: implicit in the definition (and in our
informal understanding of how datatype declarations work in other
programming languages) are two more facts:
| O : nat
| S : nat → nat.
- The constructor S is injective. That is, if S n = S m, it
must be the case that n = m.
- The constructors O and S are disjoint. That is, O is not equal to S n for any n.
Theorem S_injective : ∀ (n m : nat),
S n = S m →
n = m.
Proof.
intros n m H.
By writing inversion H at this point, we are asking Coq to
generate all equations that it can infer from H as additional
hypotheses, replacing variables in the goal as it goes. In the
present example, this amounts to adding a new hypothesis H1 : n =
m and replacing n by m in the goal.
inversion H.
reflexivity.
Qed.
Here's a more interesting example that shows how multiple
equations can be derived at once.
Theorem inversion_ex1 : ∀ (n m o : nat),
[n; m] = [o; o] →
[n] = [m].
Proof.
intros n m o H. inversion H. reflexivity. Qed.
We can name the equations that inversion generates with an
as ... clause:
Theorem inversion_ex2 : ∀ (n m : nat),
[n] = [m] →
n = m.
Proof.
intros n m H. inversion H as [Hnm]. reflexivity. Qed.
Example inversion_ex3 : ∀ (X : Type) (x y z : X) (l j : list X),
x :: y :: l = z :: j →
y :: l = x :: j →
x = y.
Proof.
(* FILL IN HERE *) Admitted.
☐
x :: y :: l = z :: j →
y :: l = x :: j →
x = y.
Proof.
(* FILL IN HERE *) Admitted.
Theorem beq_nat_0_l : ∀ n,
beq_nat 0 n = true → n = 0.
Proof.
intros n.
We can proceed by case analysis on n. The first case is
trivial.
destruct n as [| n'].
- (* n = 0 *)
intros H. reflexivity.
However, the second one doesn't look so simple: assuming
beq_nat 0 (S n') = true, we must show S n' = 0, but the latter
clearly contradictory! The way forward lies in the assumption.
After simplifying the goal state, we see that beq_nat 0 (S n') =
true has become false = true:
- (* n = S n' *)
simpl.
If we use inversion on this hypothesis, Coq notices that
the subgoal we are working on is impossible, and therefore removes
it from further consideration.
intros H. inversion H. Qed.
This is an instance of a logical principle known as the principle
of explosion, which asserts that a contradictory hypothesis
entails anything, even false things!
Theorem inversion_ex4 : ∀ (n : nat),
S n = O →
2 + 2 = 5.
Proof.
intros n contra. inversion contra. Qed.
Theorem inversion_ex5 : ∀ (n m : nat),
false = true →
[n] = [m].
Proof.
intros n m contra. inversion contra. Qed.
If you find the principle of explosion confusing, remember
that these proofs are not actually showing that the conclusion of
the statement holds. Rather, they are arguing that, if the
nonsensical situation described by the premise did somehow arise,
then the nonsensical conclusion would follow. We'll explore the
principle of explosion of more detail in the next chapter.
Exercise: 1 star (inversion_ex6)
Example inversion_ex6 : ∀ (X : Type)
(x y z : X) (l j : list X),
x :: y :: l = [] →
y :: l = z :: j →
x = z.
Proof.
(* FILL IN HERE *) Admitted.
☐
(x y z : X) (l j : list X),
x :: y :: l = [] →
y :: l = z :: j →
x = z.
Proof.
(* FILL IN HERE *) Admitted.
c a1 a2 ... an = d b1 b2 ... bm
for some constructors c and d and arguments a1 ... an and
b1 ... bm. Then inversion H has the following effect:
- If c and d are the same constructor, then, by the
injectivity of this constructor, we know that a1 = b1, a2 =
b2, etc. The inversion H adds these facts to the context and
tries to use them to rewrite the goal.
- If c and d are different constructors, then the hypothesis H is contradictory, and the current goal doesn't have to be considered at all. In this case, inversion H marks the current goal as completed and pops it off the goal stack.
Theorem f_equal : ∀ (A B : Type) (f: A → B) (x y: A),
x = y → f x = f y.
Proof. intros A B f x y eq. rewrite eq. reflexivity. Qed.
Using Tactics on Hypotheses
Theorem S_inj : ∀ (n m : nat) (b : bool),
beq_nat (S n) (S m) = b →
beq_nat n m = b.
Proof.
intros n m b H. simpl in H. apply H. Qed.
Similarly, apply L in H matches some conditional statement
L (of the form L1 → L2, say) against a hypothesis H in the
context. However, unlike ordinary apply (which rewrites a goal
matching L2 into a subgoal L1), apply L in H matches H
against L1 and, if successful, replaces it with L2.
In other words, apply L in H gives us a form of "forward
reasoning": from L1 → L2 and a hypothesis matching L1, it
produces a hypothesis matching L2. By contrast, apply L is
"backward reasoning": it says that if we know L1→L2 and we are
trying to prove L2, it suffices to prove L1.
Here is a variant of a proof from above, using forward reasoning
throughout instead of backward reasoning.
Theorem silly3' : ∀ (n : nat),
(beq_nat n 5 = true → beq_nat (S (S n)) 7 = true) →
true = beq_nat n 5 →
true = beq_nat (S (S n)) 7.
Proof.
intros n eq H.
symmetry in H. apply eq in H. symmetry in H.
apply H. Qed.
Forward reasoning starts from what is given (premises,
previously proven theorems) and iteratively draws conclusions from
them until the goal is reached. Backward reasoning starts from
the goal, and iteratively reasons about what would imply the
goal, until premises or previously proven theorems are reached.
If you've seen informal proofs before (for example, in a math or
computer science class), they probably used forward reasoning. In
general, idiomatic use of Coq tends to favor backward reasoning,
but in some situations the forward style can be easier to think
about.
Exercise: 3 stars, recommended (plus_n_n_injective)
Practice using "in" variants in this exercise. (Hint: use plus_n_Sm.)Theorem plus_n_n_injective : ∀ n m,
n + n = m + m →
n = m.
Proof.
intros n. induction n as [| n'].
(* FILL IN HERE *) Admitted.
Varying the Induction Hypothesis
Theorem double_injective: ∀ n m,
double n = double m → n = m.
The way we start this proof is a bit delicate: if we begin with
double n = double m → n = m.
intros n. induction n.
all is well. But if we begin it with
intros n m. induction n.
we get stuck in the middle of the inductive case...
Theorem double_injective_FAILED : ∀ n m,
double n = double m →
n = m.

At this point, the induction hypothesis, IHn', does not give us
n' = m' — there is an extra S in the way — so the goal is
not provable.
Abort.
What went wrong?
The problem is that, at the point we invoke the induction
hypothesis, we have already introduced m into the context —
intuitively, we have told Coq, "Let's consider some particular n
and m..." and we now have to prove that, if double n = double
m for these particular n and m, then n = m.
The next tactic, induction n says to Coq: We are going to show
the goal by induction on n. That is, we are going to prove, for
all n, that the proposition
holds, by showing
If we look closely at the second statement, it is saying something
rather strange: it says that, for a particular m, if we know
then we can prove
To see why this is strange, let's think of a particular m —
say, 5. The statement is then saying that, if we know
then we can prove
But knowing Q doesn't give us any help at all with proving
R! (If we tried to prove R from Q, we would start with
something like "Suppose double (S n) = 10..." but then we'd be
stuck: knowing that double (S n) is 10 tells us nothing about
whether double n is 10, so Q is useless.)
Trying to carry out this proof by induction on n when m is
already in the context doesn't work because we are then trying to
prove a relation involving every n but just a single m.
The successful proof of double_injective leaves m in the goal
statement at the point where the induction tactic is invoked on
n:
- P n = "if double n = double m, then n = m"
- P O
(i.e., "if double O = double m then O = m") and
- P n → P (S n)
(i.e., "if double n = double m then n = m" implies "if double (S n) = double m then S n = m").
- "if double n = double m then n = m"
- "if double (S n) = double m then S n = m".
- Q = "if double n = 10 then n = 5"
- R = "if double (S n) = 10 then S n = 5".
Theorem double_injective : ∀ n m,
double n = double m →
n = m.
Proof.
intros n. induction n as [| n'].
- (* n = O *) simpl. intros m eq. destruct m as [| m'].
+ (* m = O *) reflexivity.
+ (* m = S m' *) inversion eq.
- (* n = S n' *) simpl.
Notice that both the goal and the induction hypothesis are
different this time: the goal asks us to prove something more
general (i.e., to prove the statement for every m), but the IH
is correspondingly more flexible, allowing us to choose any m we
like when we apply the IH.
intros m eq.
Now we've chosen a particular m and introduced the assumption
that double n = double m. Since we are doing a case analysis on
n, we also need a case analysis on m to keep the two "in sync."
destruct m as [| m'].
+ (* m = O *) simpl.
The 0 case is trivial:
inversion eq.
+ (* m = S m' *)
apply f_equal.
At this point, since we are in the second branch of the destruct
m, the m' mentioned in the context is the predecessor of the
m we started out talking about. Since we are also in the S
branch of the induction, this is perfect: if we instantiate the
generic m in the IH with the current m' (this instantiation is
performed automatically by the apply in the next step), then
IHn' gives us exactly what we need to finish the proof.
apply IHn'. inversion eq. reflexivity. Qed.
What you should take away from all this is that we need to be
careful about using induction to try to prove something too
specific: To prove a property of n and m by induction on n,
it is sometimes important to leave m generic.
The following exercise requires the same pattern.
Exercise: 2 stars (beq_nat_true)
Theorem beq_nat_true : ∀ n m,
beq_nat n m = true → n = m.
Proof.
(* FILL IN HERE *) Admitted.
☐
beq_nat n m = true → n = m.
Proof.
(* FILL IN HERE *) Admitted.
Exercise: 2 stars, advancedM (beq_nat_true_informal)
Give a careful informal proof of beq_nat_true, being as explicit as possible about quantifiers.(* FILL IN HERE *)
Theorem double_injective_take2_FAILED : ∀ n m,
double n = double m →
n = m.
Proof.
intros n m. induction m as [| m'].
- (* m = O *) simpl. intros eq. destruct n as [| n'].
+ (* n = O *) reflexivity.
+ (* n = S n' *) inversion eq.
- (* m = S m' *) intros eq. destruct n as [| n'].
+ (* n = O *) inversion eq.
+ (* n = S n' *) apply f_equal.
(* Stuck again here, just like before. *)
Abort.
The problem is that, to do induction on m, we must first
introduce n. (If we simply say induction m without
introducing anything first, Coq will automatically introduce n
for us!)
What can we do about this? One possibility is to rewrite the
statement of the lemma so that m is quantified before n. This
works, but it's not nice: We don't want to have to twist the
statements of lemmas to fit the needs of a particular strategy for
proving them! Rather we want to state them in the clearest and
most natural way.
What we can do instead is to first introduce all the quantified
variables and then re-generalize one or more of them,
selectively taking variables out of the context and putting them
back at the beginning of the goal. The generalize dependent
tactic does this.
Theorem double_injective_take2 : ∀ n m,
double n = double m →
n = m.
Proof.
intros n m.
(* n and m are both in the context *)
generalize dependent n.
(* Now n is back in the goal and we can do induction on
m and get a sufficiently general IH. *)
induction m as [| m'].
- (* m = O *) simpl. intros n eq. destruct n as [| n'].
+ (* n = O *) reflexivity.
+ (* n = S n' *) inversion eq.
- (* m = S m' *) intros n eq. destruct n as [| n'].
+ (* n = O *) inversion eq.
+ (* n = S n' *) apply f_equal.
apply IHm'. inversion eq. reflexivity. Qed.
Let's look at an informal proof of this theorem. Note that
the proposition we prove by induction leaves n quantified,
corresponding to the use of generalize dependent in our formal
proof.
Theorem: For any nats n and m, if double n = double m, then
n = m.
Proof: Let m be a nat. We prove by induction on m that, for
any n, if double n = double m then n = m.
Before we close this section and move on to some exercises,
let's digress briefly and use beq_nat_true to prove a similar
property of identifiers that we'll need in later chapters:
- First, suppose m = 0, and suppose n is a number such
that double n = double m. We must show that n = 0.
Since m = 0, by the definition of double we have double n = 0. There are two cases to consider for n. If n = 0 we are done, since m = 0 = n, as required. Otherwise, if n = S n' for some n', we derive a contradiction: by the definition of double, we can calculate double n = S (S (double n')), but this contradicts the assumption that double n = 0.
- Second, suppose m = S m' and that n is again a number such
that double n = double m. We must show that n = S m', with
the induction hypothesis that for every number s, if double s =
double m' then s = m'.
By the fact that m = S m' and the definition of double, we have double n = S (S (double m')). There are two cases to consider for n.If n = 0, then by definition double n = 0, a contradiction.Thus, we may assume that n = S n' for some n', and again by the definition of double we have S (S (double n')) = S (S (double m')), which implies by inversion that double n' = double m'. Instantiating the induction hypothesis with n' thus allows us to conclude that n' = m', and it follows immediately that S n' = S m'. Since S n' = n and S m' = m, this is just what we wanted to show. ☐
Theorem beq_id_true : ∀ x y,
beq_id x y = true → x = y.
Proof.
intros [m] [n]. simpl. intros H.
assert (H' : m = n). { apply beq_nat_true. apply H. }
rewrite H'. reflexivity.
Qed.
Theorem nth_error_after_last: ∀ (n : nat) (X : Type) (l : list X),
length l = n →
nth_error l n = None.
Proof.
(* FILL IN HERE *) Admitted.
Unfolding Definitions
Definition square n := n * n.
... and try to prove a simple fact about square...
Lemma square_mult : ∀ n m, square (n * m) = square n * square m.
Proof.
intros n m.
simpl.
... we get stuck: simpl doesn't simplify anything at this point,
and since we haven't proved any other facts about square, there
is nothing we can apply or rewrite with.
To make progress, we can manually unfold the definition of
square:
unfold square.
Now we have plenty to work with: both sides of the equality are
expressions involving multiplication, and we have lots of facts
about multiplication at our disposal. In particular, we know that
it is commutative and associative, and from these facts it is not
hard to finish the proof.
rewrite mult_assoc.
assert (H : n * m * n = n * n * m).
{ rewrite mult_comm. apply mult_assoc. }
rewrite H. rewrite mult_assoc. reflexivity.
Qed.
At this point, a deeper discussion of unfolding and simplification
is in order.
You may already have observed that tactics like simpl,
reflexivity, and apply will often unfold the definitions of
functions automatically when this allows them to make progress. For
example, if we define foo m to be the constant 5...
Definition foo (x: nat) := 5.
then the simpl in the following proof (or the reflexivity, if
we omit the simpl) will unfold foo m to (fun x ⇒ 5) m and
then further simplify this expression to just 5.
Fact silly_fact_1 : ∀ m, foo m + 1 = foo (m + 1) + 1.
Proof.
intros m.
simpl.
reflexivity.
Qed.
However, this automatic unfolding is rather conservative. For
example, if we define a slightly more complicated function
involving a pattern match...
Definition bar x :=
match x with
| O ⇒ 5
| S _ ⇒ 5
end.
...then the analogous proof will get stuck:
Fact silly_fact_2_FAILED : ∀ m, bar m + 1 = bar (m + 1) + 1.
Proof.
intros m.
simpl. (* Does nothing! *)
Abort.
The reason that simpl doesn't make progress here is that it
notices that, after tentatively unfolding bar m, it is left with
a match whose scrutinee, m, is a variable, so the match cannot
be simplified further. (It is not smart enough to notice that the
two branches of the match are identical.) So it gives up on
unfolding bar m and leaves it alone. Similarly, tentatively
unfolding bar (m+1) leaves a match whose scrutinee is a
function application (that, itself, cannot be simplified, even
after unfolding the definition of +), so simpl leaves it
alone.
At this point, there are two ways to make progress. One is to use
destruct m to break the proof into two cases, each focusing on a
more concrete choice of m (O vs S _). In each case, the
match inside of bar can now make progress, and the proof is
easy to complete.
Fact silly_fact_2 : ∀ m, bar m + 1 = bar (m + 1) + 1.
Proof.
intros m.
destruct m.
- simpl. reflexivity.
- simpl. reflexivity.
Qed.
This approach works, but it depends on our recognizing that the
match hidden inside bar is what was preventing us from making
progress.
A more straightforward way to make progress is to explicitly tell
Coq to unfold bar.
Fact silly_fact_2' : ∀ m, bar m + 1 = bar (m + 1) + 1.
Proof.
intros m.
unfold bar.
Now it is apparent that we are stuck on the match expressions on
both sides of the =, and we can use destruct to finish the
proof without thinking too hard.
destruct m.
- reflexivity.
- reflexivity.
Qed.
Using destruct on Compound Expressions
Definition sillyfun (n : nat) : bool :=
if beq_nat n 3 then false
else if beq_nat n 5 then false
else false.
Theorem sillyfun_false : ∀ (n : nat),
sillyfun n = false.
Proof.
intros n. unfold sillyfun.
destruct (beq_nat n 3).
- (* beq_nat n 3 = true *) reflexivity.
- (* beq_nat n 3 = false *) destruct (beq_nat n 5).
+ (* beq_nat n 5 = true *) reflexivity.
+ (* beq_nat n 5 = false *) reflexivity. Qed.
After unfolding sillyfun in the above proof, we find that
we are stuck on if (beq_nat n 3) then ... else .... But either
n is equal to 3 or it isn't, so we can use destruct (beq_nat
n 3) to let us reason about the two cases.
In general, the destruct tactic can be used to perform case
analysis of the results of arbitrary computations. If e is an
expression whose type is some inductively defined type T, then,
for each constructor c of T, destruct e generates a subgoal
in which all occurrences of e (in the goal and in the context)
are replaced by c.
Exercise: 3 stars, optional (combine_split)
Theorem combine_split : ∀ X Y (l : list (X * Y)) l1 l2,
split l = (l1, l2) →
combine l1 l2 = l.
Proof.
(* FILL IN HERE *) Admitted.
☐
split l = (l1, l2) →
combine l1 l2 = l.
Proof.
(* FILL IN HERE *) Admitted.
Definition sillyfun1 (n : nat) : bool :=
if beq_nat n 3 then true
else if beq_nat n 5 then true
else false.
Now suppose that we want to convince Coq of the (rather
obvious) fact that sillyfun1 n yields true only when n is
odd. By analogy with the proofs we did with sillyfun above, it
is natural to start the proof like this:
Theorem sillyfun1_odd_FAILED : ∀ (n : nat),
sillyfun1 n = true →
oddb n = true.
Proof.
intros n eq. unfold sillyfun1 in eq.
destruct (beq_nat n 3).
(* stuck... *)
Abort.
We get stuck at this point because the context does not
contain enough information to prove the goal! The problem is that
the substitution performed by destruct is too brutal — it threw
away every occurrence of beq_nat n 3, but we need to keep some
memory of this expression and how it was destructed, because we
need to be able to reason that, since beq_nat n 3 = true in this
branch of the case analysis, it must be that n = 3, from which
it follows that n is odd.
What we would really like is to substitute away all existing
occurences of beq_nat n 3, but at the same time add an equation
to the context that records which case we are in. The eqn:
qualifier allows us to introduce such an equation, giving it a
name that we choose.
Theorem sillyfun1_odd : ∀ (n : nat),
sillyfun1 n = true →
oddb n = true.
Proof.
intros n eq. unfold sillyfun1 in eq.
destruct (beq_nat n 3) eqn:Heqe3.
(* Now we have the same state as at the point where we got
stuck above, except that the context contains an extra
equality assumption, which is exactly what we need to
make progress. *)
- (* e3 = true *) apply beq_nat_true in Heqe3.
rewrite → Heqe3. reflexivity.
- (* e3 = false *)
(* When we come to the second equality test in the body
of the function we are reasoning about, we can use
eqn: again in the same way, allow us to finish the
proof. *)
destruct (beq_nat n 5) eqn:Heqe5.
+ (* e5 = true *)
apply beq_nat_true in Heqe5.
rewrite → Heqe5. reflexivity.
+ (* e5 = false *) inversion eq. Qed.
Theorem bool_fn_applied_thrice :
∀ (f : bool → bool) (b : bool),
f (f (f b)) = f b.
Proof.
(* FILL IN HERE *) Admitted.
☐
∀ (f : bool → bool) (b : bool),
f (f (f b)) = f b.
Proof.
(* FILL IN HERE *) Admitted.
Review
- intros: move hypotheses/variables from goal to context
- reflexivity: finish the proof (when the goal looks like e =
e)
- apply: prove goal using a hypothesis, lemma, or constructor
- apply... in H: apply a hypothesis, lemma, or constructor to
a hypothesis in the context (forward reasoning)
- apply... with...: explicitly specify values for variables
that cannot be determined by pattern matching
- simpl: simplify computations in the goal
- simpl in H: ... or a hypothesis
- rewrite: use an equality hypothesis (or lemma) to rewrite
the goal
- rewrite ... in H: ... or a hypothesis
- symmetry: changes a goal of the form t=u into u=t
- symmetry in H: changes a hypothesis of the form t=u into
u=t
- unfold: replace a defined constant by its right-hand side in
the goal
- unfold... in H: ... or a hypothesis
- destruct... as...: case analysis on values of inductively
defined types
- destruct... eqn:...: specify the name of an equation to be
added to the context, recording the result of the case
analysis
- induction... as...: induction on values of inductively
defined types
- inversion: reason by injectivity and distinctness of
constructors
- assert (H: e) (or assert (e) as H): introduce a "local
lemma" e and call it H
- generalize dependent x: move the variable x (and anything else that depends on it) from the context back to an explicit hypothesis in the goal formula
Theorem beq_nat_sym : ∀ (n m : nat),
beq_nat n m = beq_nat m n.
Proof.
(* FILL IN HERE *) Admitted.
☐
beq_nat n m = beq_nat m n.
Proof.
(* FILL IN HERE *) Admitted.
Exercise: 3 stars, advancedM? (beq_nat_sym_informal)
Give an informal proof of this lemma that corresponds to your formal proof above:☐
Exercise: 3 stars, optional (beq_nat_trans)
Theorem beq_nat_trans : ∀ n m p,
beq_nat n m = true →
beq_nat m p = true →
beq_nat n p = true.
Proof.
(* FILL IN HERE *) Admitted.
☐
beq_nat n m = true →
beq_nat m p = true →
beq_nat n p = true.
Proof.
(* FILL IN HERE *) Admitted.
Exercise: 3 stars, advancedM (split_combine)
We proved, in an exercise above, that for all lists of pairs, combine is the inverse of split. How would you formalize the statement that split is the inverse of combine? When is this property true?Definition split_combine_statement : Prop
(* (": Prop" means that we are giving a name to a
logical proposition here.) *)
(* REPLACE THIS LINE WITH ":= _your_definition_ ." *). Admitted.
Theorem split_combine : split_combine_statement.
Proof.
(* FILL IN HERE *) Admitted.
Exercise: 3 stars, advanced (filter_exercise)
This one is a bit challenging. Pay attention to the form of your induction hypothesis.Theorem filter_exercise : ∀ (X : Type) (test : X → bool)
(x : X) (l lf : list X),
filter test l = x :: lf →
test x = true.
Proof.
(* FILL IN HERE *) Admitted.
Exercise: 4 stars, advanced, recommended (forall_exists_challenge)
Define two recursive Fixpoints, forallb and existsb. The first checks whether every element in a list satisfies a given predicate:
forallb oddb [1;3;5;7;9] = true
forallb negb [false;false] = true
forallb evenb [0;2;4;5] = false
forallb (beq_nat 5) [] = true
The second checks whether there exists an element in the list that
satisfies a given predicate:
forallb negb [false;false] = true
forallb evenb [0;2;4;5] = false
forallb (beq_nat 5) [] = true
existsb (beq_nat 5) [0;2;3;6] = false
existsb (andb true) [true;true;false] = true
existsb oddb [1;0;0;0;0;3] = true
existsb evenb [] = false
Next, define a nonrecursive version of existsb — call it
existsb' — using forallb and negb.
existsb (andb true) [true;true;false] = true
existsb oddb [1;0;0;0;0;3] = true
existsb evenb [] = false
(* FILL IN HERE *)


Tests dealing with HTTP rate-limiting.
Bases: nova.test.TestCase
Base test suite which provides relevant stubs and time abstraction.
Bases: object
Fake httplib.HTTPConnection.
Return our generated response from the request.
Requests made via this connection actually get translated and routed into our WSGI app, we then wait for the response and turn it back into an httplib.HTTPResponse.
Bases: object
Fake httplib.HTTPResponse replacement.
Returns the socket’s internal buffer.
Bases: nova.tests.api.openstack.compute.test_limits.BaseLimitTestSuite
Tests for the limits.RateLimitingMiddleware class.
Prepare middleware for use through fake WSGI app.
Test successful GET request through middleware.
Test that middleware selected correct limiter class.
Test a rate-limited (413) GET request through middleware.
Test a rate-limited (413) response as XML
Bases: nova.tests.api.openstack.compute.test_limits.BaseLimitTestSuite
Tests for the limits.Limit class.
Test two calls to 1 GET per second limit.
Test a limit handles 1 GET per second.
Bases: nova.tests.api.openstack.compute.test_limits.BaseLimitTestSuite
Tests for the in-memory limits.Limiter class.
Run before each test.
Ensure the 11th GET will result in NO delay.
Ensure the 8th POST will result in a delay of 6.0 seconds until the next request will be granced.
Ensure the 11th PUT will result in a delay of 6.0 seconds until the next request will be granced.
Ensure PUT on /servers limits at 5 requests, and PUT elsewhere is still OK after 5 requests...but then after 11 total requests, PUT limiting kicks in.
Ensure after hitting the limit and then waiting for the correct amount of time, the limit will be lifted.
Ensure multiple requests still get a delay.
Tests involving multiple users.
Simple test to ensure no delay on a single call for a limit verb we didn”t set.
Simple test to ensure no delay on a single call for a known limit.
Test user-specific limits.
Bases: nova.tests.api.openstack.compute.test_limits.BaseLimitTestSuite
Tests for limits.LimitsController class.
Run before each test.
Test getting empty limit details in JSON.
Test getting limit details in JSON.
Test getting limit details in JSON.
Bases: nova.test.TestCase
Bases: nova.test.TestCase
Bases: nova.tests.api.openstack.compute.test_limits.BaseLimitTestSuite
Tests for the default limits parser in the in-memory limits.Limiter class.
Test that parse_limits() handles bad rules correctly.
Test that parse_limits() handles bad units correctly.
Test that parse_limits() handles bad values correctly.
Test that parse_limits() handles invalid input correctly.
Test that parse_limits() handles missing args correctly.
Test that parse_limits() handles multiple rules correctly.
Bases: nova.tests.api.openstack.compute.test_limits.BaseLimitTestSuite
Tests for the limits.WsgiLimiterProxy class.
Do some nifty HTTP/WSGI magic which allows for WSGI to be called directly by something like the httplib library.
Successful request test.
Forbidden request test.
Bases: nova.tests.api.openstack.compute.test_limits.BaseLimitTestSuite
Tests for limits.WsgiLimiter class.
Run before each test.
Only POSTs should work.
Monkeypatches HTTPConnection so that if you try to connect to host, you are instead routed straight to the given WSGI app.
After calling this method, when any code calls
httplib.HTTPConnection(host)
the connection object will be a fake. Its requests will be sent directly to the given WSGI app rather than through a socket.
Code connecting to hosts other than host will not be affected.
This method may be called multiple times to map different hosts to different apps.
This method returns the original HTTPConnection object, so that the caller can restore the default HTTPConnection interface (for all hosts).


Bootstrap Sidebar
Dummy Heading
Home
About
Art
Paintings
Photography
Projects
Contact
Toggle Sidebar


Sticky element
Sticky element is an element that sticks to the top of the page while scrolling the page
You can easily transform any element into Sticky by adding just two things:
data-sticky
attribute to your elementdata-sticky-container
attribute to the parent

Sidebar Content here

...

Available options:
| Option | Type | Default | Description |
|---|---|---|---|
| data-sticky-wrap | boolean | false | When it's true sticky element is wrapped in  which has sticky element dimensions. Prevents content from "jumping". |
| data-margin-top | number | 0 | Margin between page and sticky element when scrolled |
| data-sticky-for | number | 0 | Breakpoint which when is bigger than viewport width, sticky is activated and when is smaller, then sticky is destroyed |
| data-sticky-class | string | null | Class added to sticky element when it is stuck |
Required plugin
Copy-paste the following script at the end of your page after bootstrap.bundle.min.js
to enable it.


Welcome to our little corner of the internet!
Welcome to Rogue Pickings, the roaming truck bringing you the freshest ingredients and ideas in food. Our team works hard so you can be sure our ingredients are always fresh and picked carefully. Our menu changes every day and is made with you in mind.  Check out our locations to see where you can find us.
Today's Specials
Our Awesome Services
"I got so excited about the yumminess of the falafel salad that I am typing this review as I inhale my salad. Yes, it is that good.... Service was super friendly and quick. Can't wait, see you Rogue Pickings again tomorrow!"
Contact Us
1001 Portrero Avenue
San Francisco, CA 94110
(415)216-8000


I have authored a paper which has been published in the Journal of the International Neuropsycologial Society (JINS) 2020. This paper describes the application of machine learning to the digitial clock drawing test to classify patients with the correct level of cognitive impairment.
I have authored a paper which has been published in the journal for Silicon Carbide and Related Materials 2017. I have also presented a poster on these findings at the International Conference on Silicon Carbide and Related Materials in Washington DC.
Variants of this paper have been submitted to the "Journal of the International Neuropsychological Society" and "Alzheimer's & Dementia". This paper uses clock drawing data collected from over 100 patients. Each clock contains over 200 different features. Our research included using Information Theoretic, Embedded, and Wrapper based features selection algorithms to select the best features from the set. These features were then applied to different classifiers to record the classification accuracy. When trying to distinguish between different classes of Mild Cognitive Impairment (MCI) and Alzheimer's the classifiers achieved accuracies above 85%. One application of these findings is that a physician can yearly administer the simple 2 minute clock drawing test, and based on the results, can recommend a patient for further screening.
This is my term paper for the deep learning and data mining class at Rowan University. Dota 2 is an online game with a very complex state space making it very difficult to predict the outcome of matches. This paper covers the process of collecting over 800,000 games from the Dota 2 API and designing a neural network to predict the winner. The neural network was designed to take the 5 heroes picked on each team and the game duration as inputs and try to predict the winner based only on this information. The network achieved an accuracy of 80%.
This is my term paper for the introduction to machine learning engineering clinic at Rowan University. For this project I have taken over 100 different images covering 7 different buildings on campus. I have constructed and trained a convolutional neural network (CNN) to classify these images. This network achieved a classification accuracy of 89.2%.


This is an example of how erlang graphql works with subscriptions. This is a simple chat to enter - just log in through github.
The application does not require extra rights and uses only public information.
Source code of this site availiable on github.
It uses utility classes for typography and spacing to space content out within the larger container.


My Dear I come to you with a sincere heart believing in the Almighty that you will consider my plight and come to help and also benefit from your assistance. I am Mr.Adams Michael contacting you today for a business which would be of immense benefit to you.I am a consultant based in Nigeria. I represent Mrs.Mariam Abacha, Wife of the late president of Nigeria, General Sani Abacha who died on the 8th of July 1998 while in power She has instructed me to locate a foreigner who would act as her fund manager and partner.Actually I got your contact from the Internet;please do not feel bad about it because I am compelled to reach you due to the situation I am to safeguard this money in question. Forgive me and come to my aid. Please I implore you to keep this transaction absolutely secret so you should not in any way, disclose this business to any body no matter howclose the person may be to you or your heart.I don't want people to expose it negatively or feel that you are going to be more opportuned than them and go forth to say negative prayers concerning this transaction. I want you to contact me immediately so that we can proceed with the business. She wishes to invest the sum of a millions of Dolla overseas and needs somebody to manage this investment on her behalf. As you know, assets worth several million dollars belonging to his family have been confiscated by the present Nigerian government so this project is top secret and you should not reveal it to anyone. Your fees as fund manager shall be a downpayment of 20% of the investment capital and an annual 20% of after tax returns on investment.Reach me by return mail if you are interested in this proposal so that I will give you relevant details. Regards Mr. Adams Michael


Let's first start with a definition. Arrays are ordered integer-indexed collections of objects and hashes are ordered object-indexed collections of objects. So both are collections of objects, but what's the difference between integer-indexed and object-indexed and why does this matter?
Integer-indexed collections typically include data of a similar kind where there is no major difference in the type of data and the importance is placed on simply having the data all in one place. An example of this can be seen in tagging of content with keywords on a blog site. It's important to be able to see all the keywords at one time to understand what the content is about, but the order is not particularly important. An array would be a good solution for this type of problem.
Here's an example of an array that includes keywords for this blog post. Each value is a keyword.
blog_keywords = ["array", "hash", "integer-indexed", "object-indexed"]
Object-indexed collections offer some more complexity. Instead of just having a list of data, you can specify relationships in the form of key:value pairs. Often the data will be different and it may be necessary to get access to some values, but not others. For example, on LinkedIn you can specify skills for display on your profile. This seems like a good candidate for an array, right? Well that may not be the best choice since you need a way to highlight the most important ones based on endorsements. A hash might be a good option here to capture both the skill and number of endorsements.
Here's an example of a hash that includes my skillls and the number of endorsements for each. With the data in a hash we can easily determine which ones are most important to highlight.
my_LinkedIn_skills = {customerexperience: 9, projectmanagement: 5, troubleshooting: 2, zoology: 0, rocketscience: 0}
While there is never one correct solution to every problem, I hope this helps you understand the concept of integer-indexed and object-indexed data and when to use an array vs a hash.


Diverse Classroom Libraries
We have a chance to expand classroom libraries so kids of color see themselves reflected and whiteness as the norm is interrupted for all kids. Parents will curate, fund, acquire and distribute books. The budget per teacher is $50.
The books have been selected according to these criteria:
- Fun reading. Not preachy. Will inspire the love of books.
- True to the experience of readers of color.
- Broadens coverage of racial and ethnic groups
- Fresh. Recently published or not extremely well known.
- Good writing. Teach writing by example.
- At the right reading level
To participate, teachers should review the book list, then fill in the form below. Teachers can submit the form in print by putting it in the PPTG mailbox at Peralta, or digitally by sending an email to<EMAIL_ADDRESS>Teachers are welcome to request books that are not on the list, as long as they improve library diversity.
Teachers can spend up to $50.
Order Form
| Title | Copies | Price |
|---|---|---|
Catalog
-
{{ book['Title'] }}
Grade: {{ book['Grade Min'] }}-{{ book['Grade Max'] }}
Price: {{ book['Lowest Price'] }}
Identity or theme: {{ book["Racial or ethnic identity or theme"] }}
Author: {{ book["Author"]}}
More info on the web


2. Global Warming
Heating by the greenhouse effect
Our planets surface is now kept at a comfortable temperature because the atmosphere traps some of the radiant heat from the Sun and keeps it near the surface, warming the planet and sustaining living creatures. Jean Baptise Joseph Fourier (1768-1830) first conceived the mechanism in the 1820s, while wondering how the Suns heat could be retained to keep the Earth hot. Fouriers idea, still accepted today, is that the atmosphere lets some of the Suns radiation in, but it doesnt let all of the radiation back out. Visible sunlight passes through our transparent atmosphere to warm the Earths land and oceans, and some of this heat is reradiated in infrared form. The longer infrared rays are less energetic than visible ones and do not slice through the atmosphere as easily as visible light.
So our atmosphere absorbs some of the infrared heat radiation, and some of the trapped heat is reradiated downward to warm the planets surface and the air immediately above it. Fourier likened the thin atmospheric blanket to a huge glass bell jar, made out of clouds and gases, that holds the Earths heat close to its surface.
The warming by heat-trapping gases in the air is now known as the greenhouse effect, but this is a misnomer. The air inside a garden greenhouse is heated because it is enclosed, preventing the circulation of air currents that would carry away heat and cool the interior. Nevertheless, the term is now so common that we will also sometimes designate the heat-trapping gases as greenhouse gases, and let greenhouse effect designate the process by which an atmosphere traps heat near a planets surface.
Right now, the warming influence is literally a matter of life and death. It keeps the average surface temperature of the planet at 288 degrees kelvin (15 degrees Celsius or 59 degrees Fahrenheit). Without this greenhouse effect, the average surface temperature would be 255 degrees kelvin (-18 degrees Celsius or 0 degrees Fahrenheit); a temperature so low that all water on Earth would freeze, the oceans would turn into ice and life, as we know it, would not exist.
The gases that absorb the most infrared heat radiation are minor ingredients of our atmosphere. They are water vapor and carbon dioxide, with water vapor absorbing the most. Sixty to seventy percent of the Earths greenhouse warming is now caused by water vapor and carbon dioxide provides just a few degrees.
The main constituents of the atmosphere, nitrogen (77 percent) and oxygen (21 percent) play no part in the greenhouse effect. The two atoms in these diatomic molecules are bound tightly together and are therefore incapable of absorbing significant infrared radiation. In contrast, water vapor and carbon dioxide molecules consist of three atoms that are less constrained in their motion, so they absorb the heat radiation.
Why doesnt the atmosphere just keep heating up until it explodes? The greenhouse warming rises to a fixed temperature that balances the heat input from sunlight and the heat radiated into space. The level of water in a pond similarly remains much the same even though water is running in one end and out the other.
(page 1 of 9)
Copyright 2010, Professor Kenneth R. Lang, Tufts University
|


---
layout: game-page
redirect_from: /game/lost-haven
title: Lost Haven
year: 2007
semester: Fall
description: "Save the world against massive waves of monsters!
The player is a character in a mythical 2D world. He must defeat enemies with a variety of melee and ranged weapons and any spells he creates. Better weapons and armor are are dropped by creatures when the player kills them. Monsters also drop different crystals, which can be combined to create spells with different effects. Apart from acquiring new equipment, the player can also gain levels, increasing different skills that help him in combat."
tags: Windows Singleplayer
# tag options: "Windows", "Mac", "Linux",
# "Singleplayer", "Multiplayer",
# "Controller-Compatible", "VR",
# "Game-Jam"
project_members: {
Daniel Vu: Art,
Dmitry Portnoy: "Project Lead, Programming",
Jason Cooper: Design
}
stage_game_path: losthaven/
builds: {
Windows: lost-haven-20080119.win32.exe
}
screenshots: [
losthaven-1.jpg,
losthaven-2.jpg
]
# Optional
top-img-fit: fill
# top-img-fit options:
# "cover" - Cover the entire top area with the image, without squashing/stretching
# "fill" - Fit the FULL image into the top area, squashing/stretching as necessary
---


Deal finalised for Torbay Council takeover of shopping centre
The 32 shops at Fleet Walk include some of the top high street names including TK Maxx, Sports Direct, JD Wetherspoon and Starbucks
by Edward OldfieldTorbay Council is planning to use the profits from running the Fleet Walk shopping centre in Torquay to fund improvements.
The money will go into restoring and improving the centre and car park and then into regeneration of the wider shopping area.
The deal to buy the centre for a sum believed to be approaching £20m has now been finalised.
The 32 shops at Fleet Walk include some of the top high street names including TK Maxx, Sports Direct, JD Wetherspoon and Starbucks.
It is understood the centre management has had interest from businesses in the three currently empty units.
The purchase of the centre was made under the council’s £100m Economic Regeneration Fund created this year.
The current management team is expected to stay in place.
Fleet Walk forms a key part of Torquay’s shopping centre and the council aims to use its ownership to support the vitality of the area by improving the offer and attracting more visitors.
The high street has suffered from the departure of big names, with New Look leaving in April and H&M announcing its store in the former Woolworths building was for sale and expected to close.
The switch to more leisure use received a boost in August when Merlin Cinemas was given planning permission to convert the empty former BHS store in Union Street into a new 13-screen cinema.
Other regeneration schemes under way include the £32m redevelopment of Torwood Street near Torquay Harbour.
The project will see the creation of a 130-bed Hilton Hotel, new offices, bars and restaurants.
Torbay Council is funding the £11m build of a Premier Inn hotel on The Terrace car park above the harbour.
Work has started to prepare the site ahead of the main construction work on the six-floor 120-bed hotel.
Along the seafront, the council is working with tenant the Venus Cafe on plans to convert the empty Old Toll House into a restaurant and bar.


Changes successfully saved
Public info
Input is incorrect
About me:
Website:
Apply
JPG or PNG, preferably square (will be resized to 160x160 and 28x28), max size 1 MB
Change picture
Remove
Avatar successfully saved


Johnson tells EU he will not appoint a new UK commissioner
The Government said pre-election guidance states it should not make international appointments ahead of polling on December 12.
Britain will not appoint a new EU commissioner despite demands from Brussels to do so, the Government has confirmed.
Britain’s ambassador to the EU Sir Tim Barrow sent a letter to European Commission headquarters on Thursday confirming the decision.
A Government spokesman said: “We have written to the EU to confirm that pre-election guidance states the UK should not normally make nominations for international appointments during this period.”
The incoming European Commission president Ursula von der Leyen has twice written to Mr Johnson demanding he provide a nomination to the new commission, in line with its obligations as a member state.
European Commission spokeswoman Dana Spinant said they were considering how to respond to the UK letter.
It is an exceptional situation, we haven't been there beforeDana Spinant, European Commission
She said it was still Ms von der Leyen’s intention to go ahead with the formation of a new College of Commissioners on December 1, even though legally all member states are required to supply a commissioner.
“We have had a few hours to consider the answer provided by the United Kingdom. This is a very special and complex situation,” she told reporters in Brussels.
“It is an exceptional situation, we haven’t been there before.
“Therefore all options and avenues are being discussed right now to see how we can – based on the position the UK has taken – achieve the forming of the next commission and have the commission in place by December 1, which remains our objective.”


src/app/vehicle/vehicle.service.ts
The Vehicle Service is responsible for most of the data logic. It gets the data, it's also the job of the Service to keep track of the data and do some logic thing on them
Properties |
Methods |
constructor(sfService: FilterService)
|
||||||||
|
Defined in src/app/vehicle/vehicle.service.ts:61
|
||||||||
|
Construct with injecting the FilterService and try to get the vehicles from the data source right away.
Parameters :
|
| cleanDuplicates | ||||||||
cleanDuplicates(arr: any[])
|
||||||||
|
Defined in src/app/vehicle/vehicle.service.ts:158
|
||||||||
|
Clean duplicates in the lists with Array.filter and sort them alphabetically at the end, a little UX friendlier.
Parameters :
Returns :
any[]
|
| filterDataList |
filterDataList()
|
|
Defined in src/app/vehicle/vehicle.service.ts:144
|
|
Just a method to filter the main vehicles array according to the parameter that were chosen in the filters
Returns :
Vehicle[]
|
| getVehiclesObservable |
getVehiclesObservable()
|
|
Defined in src/app/vehicle/vehicle.service.ts:179
|
|
Get the vehicleObservable to subscribe on. This method creates and Observabble, fetches the data, waits for the callback function to react and then reply accordingly by nexting or erroring
Returns :
Observable<Vehicle[]>
|
| hasError |
hasError()
|
|
Defined in src/app/vehicle/vehicle.service.ts:199
|
|
This function return an error of any type so the outside world can read it an act accordingly
Returns :
any
|
| isLoading |
isLoading()
|
|
Defined in src/app/vehicle/vehicle.service.ts:207
|
|
This function returns the loading boolean 'state'
Returns :
boolean
|
| listAttributes | ||||||||||||
listAttributes(vehicleList: Vehicle[], attributeArray: string[], attribute: string)
|
||||||||||||
|
Defined in src/app/vehicle/vehicle.service.ts:131
|
||||||||||||
|
Make the lists and return a string array with the values that will populate the Radio Buttons
Parameters :
Returns :
string[]
|
| makeLists |
makeLists()
|
|
Defined in src/app/vehicle/vehicle.service.ts:110
|
|
The 'List Maker' cleans the arrays by making every item unique. these arrays will populate the Radio Buttons for the filter this function is also called when the filters are changed, if the result of the change is one item then that's the selected item.
Returns :
void
|
| tryGettingVehicles |
tryGettingVehicles()
|
|
Defined in src/app/vehicle/vehicle.service.ts:75
|
|
Try getting the vehicles from the Data source, since this is an Observable we can conveniently subscribe to it and do some stuff on the next(), err() and complete() methods.
Returns :
void
|
| vehicleChoice |
vehicleChoice:
|
Type : Vehicle
|
|
Defined in src/app/vehicle/vehicle.service.ts:23
|
|
The chosen vehicle. This variable is being set once all Filter fields are filled. |
| vehicles |
vehicles:
|
Type : Vehicle[]
|
Default value : []
|
|
Defined in src/app/vehicle/vehicle.service.ts:18
|
|
A Container of Vehicles |
import {Injectable} from '@angular/core';
import {Vehicle} from './verhicle.model';
import * as trafficMeister from '../../assets/tm-data/index.js';
import {Observable} from 'rxjs/index';
import {FilterService} from '../filter/filter.service';
/**
* The Vehicle Service is responsible for most of the data logic.
* It gets the data, it's also the job of the Service to keep track of the data and do some logic thing on them
*/
@Injectable({
providedIn: 'root'
})
export class VehicleService {
/**
* A Container of Vehicles
* @type {Array}
*/
vehicles: Vehicle[] = [];
/**
* The chosen vehicle. This variable is being set once all Filter fields are filled.
* @type {Vehicle}
*/
vehicleChoice: Vehicle;
/**
* List of all unique types for the filter.
* @ignore
*/
private types: string[] = [];
/**
* List of all unique types for the filter.
* @ignore
*/
private brands: string[] = [];
/**
* List of all unique brands for the filter.
* @ignore
*/
private colors: string[] = [];
/**
* Error variable to keep track of the errors
* @ignore
*/
private error = null;
/**
* Variable to keep track of the loading 'state'
* @ignore
*/
private loading = true;
/**
* Variable to keep track of the total number of attempts to reconnect after an error
* @ignore
*/
private attempt = 0;
/**
* Variable to set the maximum number of attempts
* @ignore
*/
private maxAttempts = 3;
/**
* Construct with injecting the FilterService and try to get the vehicles from the data source right away.
* @param sfService inject the Filter Service to be up to date with the changed filters
*/
constructor(private sfService: FilterService) {
this.tryGettingVehicles();
}
/**
* Try getting the vehicles from the Data source, since this is an Observable we can conveniently subscribe to it and
* do some stuff on the next(), err() and complete() methods.
*/
tryGettingVehicles(): void {
// get the subscription so we can unsubscribe when we are done.
const subscription = this.getVehiclesObservable()
// subscribe to the Observable
.subscribe(
// If data is resolved then: Yay! Do the logic
(data) => {
// Put data inside a variable for later reference
this.vehicles = data;
// Make the list right away after successful fetching
this.makeLists();
},
// Sometimes shit happens, try to be aware of that fact.
(err) => {
if (this.canTry()) {
this.tryGettingVehicles();
this.raiseAttempts();
} else {
this.loading = false;
this.error = err;
}
subscription.unsubscribe();
},
() => {
this.loading = false;
subscription.unsubscribe();
}
);
}
/**
* The 'List Maker' cleans the arrays by making every item unique. these arrays will populate the Radio Buttons
* for the filter this function is also called when the filters are changed, if the result of the change
* is one item then that's the selected item.
*/
makeLists() {
this.types = this.listAttributes(this.filterDataList(), this.types, 'type');
this.brands = this.listAttributes(this.filterDataList(), this.brands, 'brand');
this.colors = this.listAttributes(this.filterDataList(), this.colors, 'colors');
if (this.filterDataList().length === 1) {
this.filterDataList().map(vehicle => this.vehicleChoice = vehicle);
} else {
this.vehicleChoice = null;
}
}
/**
* Make the lists and return a string array with the values that will populate the Radio Buttons
*
* @Param vehicleList: a list of vehicle object to iterate through whilst getting the values for the list
* @Param attributeArray: A list of strings to hold the values for the Radio Buttons.
* @Param attribute: A selector for the key that will be used to get the items for the attributeArray
* @returns {string[]}
*/
listAttributes(vehicleList: Vehicle[], attributeArray: string[], attribute: string): string[] {
attributeArray = [];
// Iterate through the object and push the items to the array.
vehicleList.forEach((vehicle: Vehicle) => {
attributeArray.push(vehicle[attribute]);
});
// remove any duplicate values, who needs that...?
return this.cleanDuplicates(attributeArray);
}
/**
* Just a method to filter the main vehicles array according to the parameter that were chosen in the filters
*/
filterDataList(): Vehicle[] {
return this.vehicles.filter((vehicle: Vehicle) => {
const typeCondition = vehicle.type === this.sfService.filters.type || this.sfService.isTypeEmpty();
const brandCondition = vehicle.brand === this.sfService.filters.brand || this.sfService.isBrandEmpty();
const colorCondition = vehicle.colors.filter((color) => color === this.sfService.filters.color).length > 0 || this.sfService.isColorEmpty();
return typeCondition && brandCondition && colorCondition;
});
}
/**
* Clean duplicates in the lists with Array.filter and sort them alphabetically at the end, a little UX friendlier.
* @param arr Provided array to clean dublicates.
* @returns {any[]}
*/
cleanDuplicates(arr: any[]): any[] {
let tempArr = [];
if (Array.isArray(arr[0])) {
arr.forEach((colorArr) => {
colorArr.forEach((color) => {
tempArr.push(color);
});
});
} else {
tempArr = arr;
}
tempArr.sort();
return tempArr.filter((item, itemIndex, me) => itemIndex === me.indexOf(item));
}
/**
* Get the vehicleObservable to subscribe on. This method creates and Observabble, fetches the data, waits for
* the callback function to react and then reply accordingly by nexting or erroring
*
* @returns {Observable<Vehicle[]>}
*/
getVehiclesObservable(): Observable<Vehicle[]> {
// Since the data API is a callback API I create an observable attach the observer to it and call next on it
// when the data from the callback function is returned. Otherwise I throw an error that is being checked for
// by the 'Global Error Component'
return Observable.create((observer) => {
trafficMeister.fetchData((err, data) => {
if (err) {
observer.error(err);
} else {
observer.next(data as Vehicle[]);
}
observer.complete();
});
});
}
/**
* This function return an error of any type so the outside world can read it an act accordingly
* @returns {any}
*/
hasError(): any {
return this.error;
}
/**
* This function returns the loading boolean 'state'
* @returns {boolean}
*/
isLoading(): boolean {
return this.loading;
}
/**
* this function returns a boolean check to see if we can try again or the maximum atempts are reached.
* @ignore
*/
private canTry(): boolean {
return this.attempt !== this.maxAttempts;
}
/**
* This function raises the attemptnumber when a try fails.
* @ignore
*/
private raiseAttempts(): void {
this.attempt++;
}
}


{% extends "layouts/layout.html" %} {% block title %}Email sent{% endblock %} {% block body %}
We've sent a link to {{email}}.
If it hasn't arrived, check your junk email folder or request a new email.


A practical guide to work with Sketch & Framer
I'm Davo Galavotti
Interaction Designer
Buenos Aires
New York
Agenda
- Framer: Demos
- Framer: The essentials
- Sketch: Methods to importing your artwork
- Sketch & Framer: Trade offs
- Sketch & Framer: Reusing UI components
- Resources to keep learning
- Connect with the community
More?
Dribbble: https://bit.ly/framerShots
- CoffeeScript: Indentation
- CoffeeScript: Variables
- CoffeeScript: Functions
- Framer: Layers
- Framer: Animations
- Framer: States
- Framer: Events
- Framer: Layer Draggable
- Framer: Scroll Component
- Framer: For Loop
Framer offers a fully integrated import workflow
MNML from UI8
Link: MNML UI Kit
UI Kit for Sketch, Figma & Photoshop
Sketch: Methods to import your artwork
Method 01
Framer Import
How to prepare your artwork?
Import Sketch artwork into Framer
Framer groups any layer group
(containing at least a single layer)
as a layer
Method 02
Copy & Paste into Framer Design
Resources to keep learning
Connect with the community


Querying server, please wait...
There were {{selectedResources.entry.length}} resources located. Please select the 'results' tab to select the one you want.
(There's a bug at the moment and I can't do it for you!)
Sorry, there were no resources that matched that query ({{searchString}}).
Try again with a more general search (eg a smaller search string)
Results {{selectedResources.entry.length}}
{{ResourceUtilsSvc.getOneLineSummaryOfResource(ent.resource);}}
{{selectedResource | json}}


| Number of Classes | Line Coverage | Mutation Coverage |
|---|---|---|
| 13 | 85% | 75% |
| Name | Line Coverage | Mutation Coverage |
|---|---|---|
| FirstMoment.java | 91% |
69% |
| FourthMoment.java | 90% |
89% |
| GeometricMean.java | 85% |
65% |
| Kurtosis.java | 94% |
89% |
| Mean.java | 91% |
71% |
| SecondMoment.java | 87% |
86% |
| SemiVariance.java | 63% |
66% |
| Skewness.java | 94% |
81% |
| StandardDeviation.java | 76% |
56% |
| ThirdMoment.java | 100% |
90% |
| Variance.java | 91% |
73% |
| VectorialCovariance.java | 75% |
62% |
| VectorialMean.java | 74% |
68% |


A range request comes
from a
client that wants only some subset of
an HTTP response. They are sometimes used to resume a failed transfer
of a large file. Squid isn't yet able to cache
partial responses and thus must make a decision when forwarding a
range request: either remove the Range header or
leave it in. If Squid leaves the Range header in, the origin
server sends only the subset that the client wants, and the client
receives the response immediately. However, this partial response
isn't cached. On the other hand, if Squid removes the header before forwarding, it
receives the entire response, which may be cached. Squid is then
responsible for ensuring that the client receives only the subset it
needs. The origin server may send a lot of data the client
doesn't want. Depending on the speed of your
connection, the client may be forced to wait a long time until its
range is available. If the beginning of the requested range is larger than the
range_offset_limit value, Squid forwards the
Range header and doesn't cache
the response. Setting range_offset_limit to
0 causes Squid to always forward the
Range header (the default). Setting it to
-1 causes Squid to never forward the header. |
Syntax
|
range_offset_limit size-specification
| |
Default
|
range_offset_limit 0 KB
| |
Example
|
range_offset_limit 100 KB
|
|


Next you will test the control inereface in 36 different target configurations. Press "I'm ready!" to get the next configuration. The target will appear after the countdown. Try to get the object to the target as fast as possible.


{% extends '../tutorials/tutbaselayout.html' %} {% load static %} {% block content %}
Before we study the basic building blocks of the C programming language, let us look at a bare minimum C program structure so that we can take it as a reference in the upcoming chapters.
A C program basically consists of the following parts −
Let us look at a simple code that would print the words "Hello World" −
#include <stdio.h>
int main() {
/* my first program in c */
printf("Hello ,World!!\n");
return 0;
}
Let us take a look at the various parts of the above program −
Let us see how to save the source code in a file, and how to compile and run it. Following are the simple steps −
$ gcc hello.c $ ./a.out Hello, World!
Make sure the gcc compiler is in your path and that you are running it in the directory containing the source file hello.c.


?
Back
Save & Connect
WiFi setup
Connect to existing network
Scan
Network name (SSID, empty to not connect):
Network password:
Static IP (leave at <IP_ADDRESS> for DHCP):
.
.
.
Static gateway:
.
.
.
Static subnet mask:
.
.
.
mDNS address (leave empty for no mDNS):
http://
.local
Client IP:
Not connected
Configure Access Point
AP SSID (leave empty for no AP):
Hide AP name:
AP password (leave empty for open):
Access Point WiFi channel:
AP opens:
No connection after boot
Disconnected
Always
Never (not recommended)
AP IP:
Not active
Experimental
Disable WiFi sleep:
Can help with connectivity issues.
Do not enable if WiFi is working correctly, increases power consumption.
Wireless Remote
Listen for events over ESP-NOW
Keep disabled if not using a remote, increases power consumption.
Enable Remote:
Hardware MAC:
Last Seen:
None
Ethernet Type
None
ABC! WLED V43 & compatible
ESP32-POE
ESP32Deux
KIT-VE
QuinLED-Dig-Octa & T-ETH-POE
QuinLED-ESP32
Serg74-ETH32
TwilightLord-ESP32
WESP32
WT32-ETH01
Back
Save & Connect


Tweaks
Keyhook
ClassicShutterAnimation
Note
If you ever have any problems with tweaks, just contact me!


All Classes
AudioPlayer
Controller
Employee
Item
ItemType
Main
MonitorType
MoviePlayer
MultimediaControl
Product
Product.Widget
ProductionRecord
Screen
ScreenSpec


Listing
Publish
If you cannot find the module in the listing, you may create one and publish it here. Just follow these 4 simple steps:
Convert your group to a supergroup.
Rename the group to be in the form of "CS1231 Discussion".
Add @NUSModchatBot into the chat as an administrator.
Execute the /start command.


MindRetrieve is a personal search engine. Unlike general purpose search engines that intent to index and search every web page in the world, MindRetrieve focus on a small but very special area. That is the web that you have seen.
Everyday we read a large amount of information from the world wide web. The truth is most of them does not register. We often search for similar topics time after time. It is time consuming. Often after much work we find that we are looking at the same old documents like a déjà vu. MindRetrieve is here to help you to find information buried deep in your memory.
MindRetrieve is a lightweight, cross-platform, open source application available under the BSD license. It works with all popular web browsers.
For more information, see the readme, FAQ or some development notes.


About sound of colleagues!
Sound of Colleagues is the result of a creative collaboration between the advertising agency Familjen STHLM and audio branding agency Red Pipe Studios. It was created as a reaction to this spring’s strict work from home policies in Sweden. Enjoy!
Advertising agency
Familjen STHLM
<EMAIL_ADDRESS>+46 70 317 91 07
familjen.se
Audio branding agency
Red Pipe Studios
<EMAIL_ADDRESS>+46 8 459 03 90
redpipe.com
Thanks for visiting!


Jessica Jones
Oct 12, 2019
Learn to become a modern Frontend Developer in 2019
Web Development is an ever-changing field — the way we build websites today is completely different from how we used to do it a couple of years ago. With the plethora of tools available and the new ones popping up every day, most of the time developers find themselves confused about which way to go.
I am the author and maintainer of “Developer Roadmap” which lists down the roadmap, the tools, and technologies that you would want to learn to get into the frontend, backend or the operations. I initially created these roadmaps in 2017, then updated in 2018 and most recently revised in 2019. At the time of this writing, frontend developer roadmap has been updated for the current year. I am still working upon the Backend and Operations/DevOps roadmaps and will hopefully release it in the next few days.
In this post, I am going to recap a bit and share with you the motivation behind making these roadmaps, a few disclaimers if you decide to follow these roadmaps and finally have a breakdown and tips on how to learn if you were to become a modern frontend developer in 2019
Jean Marie
Oct 2, 2019


< NS />
NitroSauce
Networking Services and Solution Provider, by Naoki Rinmous.
Homepage is still under construction, currently :<
Networking Services and Solution Provider, by Naoki Rinmous.
Homepage is still under construction, currently :<
Host your applications and web sites
Internet-access accelerator and helper
Take care of your servers and users
Host your applications and web sites
But easier and powerful for you
Stand for Infrastructure as a Service, or Iowa as a Ship (probably)


 The resulting graph has one less edge than G . A graph H is a minor of a graph G if a copy of H can be obtained from G via repeated edge deletion, edge contraction and isolated node deletion.
Minors play an important role in graph theory. For example, every non-planar graph contains either the graph K3, 3 (i.e., the complete bipartite graph on two sets of three vertices) or the complete graph K5 as a graph minor.
Write a program to find a graph minor Kn, m or Kn in an undirected connected simple graph.
The input consists of several test cases. The first line of each case contains an integers V (3<=V<=12) , the number of vertices in the graph, followed by a string in format “Kn " or “Kn ,m " (1<=n, m<=V) , the graph minor you’re finding. The following V lines contain the adjacency matrix of the graph (1 means directly connected, 0 means not directly connected).
The diagonal elements of the matrix will always be 0, and the element in row i column j is always equal to the element in row j column i . The last test case is followed by a single zero, which should not be processed.
The input consists of several test cases. The first line of each case contains an integers V (3<=V<=12) , the number of vertices in the graph, followed by a string in format “Kn " or “Kn ,m " (1<=n, m<=V) , the graph minor you’re finding. The following V lines contain the adjacency matrix of the graph (1 means directly connected, 0 means not directly connected).
The diagonal elements of the matrix will always be 0, and the element in row i column j is always equal to the element in row j column i . The last test case is followed by a single zero, which should not be processed.
5 K2,2
0 1 1 1 1
1 0 0 0 0
1 0 0 0 0
1 0 0 0 0
1 0 0 0 0
4 K3
0 1 0 1
1 0 1 0
0 1 0 1
1 0 1 0
4 K2,2
0 1 0 1
1 0 1 1
0 1 0 1
1 1 1 0
5 K2,2
0 1 0 0 1
1 0 0 0 1
0 0 0 1 1
0 0 1 0 1
1 1 1 1 0
5 K4
0 1 0 1 1
1 0 1 1 0
0 1 0 1 1
1 1 1 0 1
1 0 1 1 0
0
Case 1: Not found
Case 2: Found
Case 3: Found
Case 4: Not found
Case 5: Found
(adsbygoogle = window.adsbygoogle || []).push({});
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
唉 ，搞不明白哪来的那么多喷子！
很好的方法，学习了
分三种情况讨论。Not Possible就是impossible
看似简单，还是不少坑的
请不要灌水，多谢！
这个才是我想要的
思路二可以用一个长度为k的队列来实现，入队后判断下队尾元素的next指针是否为空，若为空，则出队指针即为所求。
不是HDU 2411。。标题党么。。。
是穷举，但是代码有优化（v数组），并不是2^n。测试数据应该没问题，之前有超时的代码。
信息不全
http://beeder.me 这个网站上有很多poj和hihoCoder的题解，质量不错，欢迎转载。
多谢指出，已改正
很赞的解答
。。。


It looks that you're not authorized to see that page you wanted. If you haven't been granted access, any admin with conductor-ui access can help. You have been granted access? Well, then it's a bug, and it's outrageous, egregious or even preposterous.
In any case, please let me know:


Tik-Tok of Oz
by L. Frank Baum
Chapter 15: “The Dragon Defies Danger”
Additional Information
- Year Published: 1914
- Language: English
- Country of Origin: United States of America
- Source: Baum, L. F. (1914). Tik-Tok of Oz. Chicago: Reilly and Britton.
-
Readability:
- Flesch–Kincaid Level: 7.0
- Word Count: 1,695
- Genre: Fantasy
- Keywords: 20th century literature, american literature, books of oz, children's literature, fantasy, l. frank baum
- ✎ Cite This
Downloads
Although the journey through the Tube was longer, this time, than before, it was so much more comfortable that none of our friends minded it at all. They talked together most of the time and as they found the dragon good-natured and fond of the sound of his own voice they soon became well acquainted with him and accepted him as a companion.
“You see,” said Shaggy, in his frank way, “Quox is on our side, and therefore the dragon is a good fellow. If he happened to be an enemy, instead of a friend, I am sure I should dislike him very much, for his breath smells of brimstone, he is very conceited and he is so strong and fierce that he would prove a dangerous foe.”
“Yes, indeed,” returned Quox, who had listened to this speech with pleasure; “I suppose I am about as terrible as any living thing. I am glad you find me conceited, for that proves I know my good qualities. As for my breath smelling of brimstone, I really can’t help it, and I once met a man whose breath smelled of onions, which I consider far worse.”
“I don’t,” said Betsy; “I love onions.
“And I love brimstone,” declared the dragon, “so don’t let us quarrel over one another’s peculiarities.”
Saying this, he breathed a long breath and shot a flame fifty feet from his mouth. The brimstone made Betsy cough, but she remembered about the onions and said nothing.
They had no idea how far they had gone through the center of the earth, nor when to expect the trip to end. At one time the little girl remarked:
“I wonder when we’ll reach the bottom of this hole. And isn’t it funny, Shaggy Man, that what is the bottom to us now, was the top when we fell the other way?”
“What puzzles me,” said Files, “is that we are able to fall both ways.”
“That,” announced Tik-Tok, “is be-cause the world is round.”
“Exactly,” responded Shaggy. “The machinery in your head is in fine working order, Tik-Tok. You know, Betsy, that there is such a thing as the Attraction of Gravitation, which draws everything toward the center of the earth. That is why we fall out of bed, and why everything clings to the surface of the earth.”
“Then why doesn’t everyone go on down to the center of the earth?” inquired the little girl.
“I was afraid you were going to ask me that,” replied Shaggy in a sad tone. “The reason, my dear, is that the earth is so solid that other solid things can’t get through it. But when there’s a hole, as there is in this case, we drop right down to the center of the world.”
“Why don’t we stop there?” asked Betsy.
“Because we go so fast that we acquire speed enough to carry us right up to the other end.”
“I don’t understand that, and it makes my head ache to try to figure it out,” she said after some thought. “One thing draws us to the center and another thing pushes us away from it. But—”
“Don’t ask me why, please,” interrupted the Shaggy Man. “If you can’t understand it, let it go at that.”
“Do you understand it?” she inquired.
“All the magic isn’t in fairyland,” he said gravely. “There’s lots of magic in all Nature, and you may see it as well in the United States, where you and I once lived, as you can here.”
“I never did,” she replied.
“Because you were so used to it all that you didn’t realize it was magic. Is anything more wonderful than to see a flower grow and blossom, or to get light out of the electricity in the air? The cows that manufacture milk for us must have machinery fully as remarkable as that in Tik-Tok’s copper body, and perhaps you’ve noticed that—”
And then, before Shaggy could finish his speech, the strong light of day suddenly broke upon them, grew brighter, and completely enveloped them. The dragon’s claws no longer scraped against the metal Tube, for he shot into the open air a hundred feet or more and sailed so far away from the slanting hole that when he landed it was on the peak of a mountain and just over the entrance to the many underground caverns of the Nome King.
Some of the officers tumbled off their seats when Quox struck the ground, but most of the dragon’s passengers only felt a slight jar. All were glad to be on solid earth again and they at once dismounted and began to look about them. Strangely enough, as soon as they had left the dragon, the seats that were strapped to the monster’s back disappeared, and this probably happened because there was no further use for them and because Quox looked far more dignified in just his silver scales. Of course he still wore the forty yards of ribbon around his neck, as well as the great locket, but these only made him look “dressed up,” as Betsy remarked.
Now the army of nomes had gathered thickly around the mouth of the Tube, in order to be ready to capture the band of invaders as soon as they popped out. There were, indeed, hundreds of nomes assembled, and they were led by Guph, their most famous General. But they did not expect the dragon to fly so high, and he shot out of the Tube so suddenly that it took them by surprise. When the nomes had rubbed the astonishment out of their eyes and regained their wits, they discovered the dragon quietly seated on the mountainside far above their heads, while the other strangers were standing in a group and calmly looking down upon them.
General Guph was very angry at the escape, which was no one’s fault but his own.
“Come down here and be captured!” he shouted, waving his sword at them.
“Come up here and capture us—if you dare!” replied Queen Ann, who was winding up the clockwork of her Private Soldier, so he could fight more briskly.
Guph’s first answer was a roar of rage at the defiance; then he turned and issued a command to his nomes. These were all armed with sharp spears and with one accord they raised these spears and threw them straight at their foes, so that they rushed through the air in a perfect cloud of flying weapons.
Some damage might have been done had not the dragon quickly crawled before the others, his body being so big that it shielded every one of them, including Hank. The spears rattled against the silver scales of Quox and then fell harmlessly to the ground. They were magic spears, of course, and all straightway bounded back into the hands of those who had thrown them, but even Guph could see that it was useless to repeat the attack.
It was now Queen Ann’s turn to attack, so the Generals yelled “For—ward march!” and the Colonels and Majors and Captains repeated the command and the valiant Army of Oogaboo, which seemed to be composed mainly of Tik- Tok, marched forward in single column toward the nomes, while Betsy and Polychrome cheered and Hank gave a loud “Hee-haw!” and Shaggy shouted “Hooray!” and Queen Ann screamed: “At ‘em, Tik-Tok—at ‘em!”
The nomes did not await the Clockwork Man’s attack but in a twinkling disappeared into the underground caverns. They made a great mistake in being so hasty, for Tik-Tok had not taken a dozen steps before he stubbed his copper toe on a rock and fell flat to the ground, where he cried: “Pick me up! Pick me up! Pick me up!” until Shaggy and Files ran forward and raised him to his feet again.
The dragon chuckled softly to himself as he scratched his left ear with his hind claw, but no one was paying much attention to Quox just then.
It was evident to Ann and her officers that there could be no fighting unless the enemy was present, and in order to find the enemy they must boldly enter the underground Kingdom of the nomes. So bold a step demanded a council of war.
“Don’t you think I’d better drop in on Ruggedo and obey the orders of the Jinjin?” asked Quox.
“By no means!” returned Queen Ann. “We have already put the army of nomes to flight and all that yet remains is to force our way into those caverns, and conquer the Nome King and all his people.”
“That seems to me something of a job,” said the dragon, closing his eyes sleepily. “But go ahead, if you like, and I’ll wait here for you. Don’t be in any hurry on my account. To one who lives thousands of years the delay of a few days means nothing at all, and I shall probably sleep until the time comes for me to act.”
Ann was provoked at this speech.
“You may as well go back to Tititi-Hoochoo now,” she said, “for the Nome King is as good as conquered already.”
But Quox shook his head. “No,” said he; “I’ll wait.”


--- layout: default title: Announcements ---
RIT's email does not like the public list. Please subscribe on CampusGroups if you're an RIT student, or email {{ site.email }} to be added on CampusGroups if you have an RIT email but are not a student.
{% for post in site.categories.announcements limit:30 %} {% include content-blocks/post-preview.html %} {% endfor %} View Older