muzang-plugins 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +17 -0
- data/Gemfile +4 -0
- data/Rakefile +11 -0
- data/lib/muzang-plugins.rb +11 -0
- data/lib/muzang-plugins/helpers.rb +39 -0
- data/lib/muzang-plugins/muzang-eval.rb +51 -0
- data/lib/muzang-plugins/muzang-livereload.rb +19 -0
- data/lib/muzang-plugins/muzang-meme.rb +51 -0
- data/lib/muzang-plugins/muzang-motd.rb +21 -0
- data/lib/muzang-plugins/muzang-nerdpursuit.rb +95 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/algorithms/fastes_sorting_algorithm.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/algorithms/run_time_of_bst.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/bash/last_cmd_sub.json +13 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/bash/last_directory.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/bash/prefix_last_command.json +13 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/couchdb/new_database.json +10 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/css/attribute_selectors.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/css/background_image.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/css/float_left.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/css/hexadecimal_code.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/css/how_do_you_use_multiple_box_sha.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/css/media.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/css/position_fixed_support.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/css/position_property.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/css/release_date.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/css/roses.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/css/z-index_property.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/culture/all_ur_base.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/culture/answer_to_everything.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/culture/club_mate_caffeine.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/culture/ook_ook.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/culture/prediction_gates.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/culture/the_cake.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/culture/to_which_year_marty_mcfly_wants.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/culture/what_is_a_traditional_vulcan_sa.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/culture/what_is_the_c_base.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/culture/when_life_gives_you_lemons.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/culture/where_are_the_characters_of_daw.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/culture/which_character_in_star_trek_se.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/culture/who_is_the_first_character_to_b.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/culture/yo_dawg.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/data/half_a_byte.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/flash/fps.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/flash/trace_something_in_as3.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/grafix/png.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/grafix/ps_save_for_web.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/grafix/screen_image_resolution.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/html/how_do_you_specify_html5_doctyp.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/html/img_tag.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/html/optional_html_tags.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/html/strict_doctype.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/http/HTCPCP.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/chrome_v8.json +10 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/fun_with_brackets.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/how_can_you_access_the_data_pas.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/jquery_sizzle.json +10 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/json.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/jsonp.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/nodetype_of_text_node.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/same_origin_policy.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/string_object_coercion_internals.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/typeof_arguments.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/valid_function_expression.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/what_s_4_2.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/what_s_typeof_null.json +12 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/who_created_jquery.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/php/invited-php.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/python/square_numbers_in_list.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/rails/controller_action.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/rails/folders.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/rails/pluralize_person.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/rails/rails_first_shown.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/rails/rails_inventor.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/rails/rake_about.json +11 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/rails/simple_format.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/regex/emails.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/regex/lazy.json +13 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/regex/min_max_quantifier.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/regex/negative_look_ahead.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/regex/prime.json +10 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/2_seconds.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/about_ruby.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/absolute_superclass_1.8.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/absolute_superclass_1.9.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/active_record_base.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/array_all_but_the_first.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/array_all_but_the_first_and_last .json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/array_all_but_the_last.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/array_ampersand.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/array_get_and remove_first_element.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/array_get_and remove_last_element.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/array_pipe.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/array_splat.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/array_to_csv_string.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/backticks_in_ruby.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/base_object.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/best_language.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/bitwise_and.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/bitwise_or.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/class_inheritance.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/collect_alternative.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/comparsion.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/constants.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/date_format_month.json +10 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/divmod.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/enumerable.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/equality.json +13 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/falsy.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/fizzbuzz.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/garbarge_collector_in_19.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/global_variable_character.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/hash_with_indifferent_access.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/how_is_ruby_licensed.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/how_many_gems.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/instance_exec.json +10 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/kanji_converter.json +10 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/kernel-sprintf-2.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/kernel-sprintf.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/kernel.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/matz.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/method_used_for_comparisions.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/mixins_are_what.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/new_lambda_calling_syntax.json +13 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/new_lambda_constructing_syntax.json +10 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/nil.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/nil_id.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/nilclass.json +10 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/numeric_types.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/private_method_in_ruby.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/protected_method_in_ruby.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/quo.json +10 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/ranges_three_dots.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/return_value_or.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/rspec_controller_render_views.json +10 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/spaceship_operator.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/string_clean_whitespace.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/sum_things_up.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/symbol_identity_01.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/symbol_identity_02.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/symbol_identity_03.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/symbol_string_ids.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/symbols.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/the_difference_between_and_operators.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/unless_wtf.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/weakref.json +10 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/what_did_matz_say_about_ruby.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/what_do_array.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/what_do_string.json +14 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/what_does_gil_stands_for.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/what_does_negate_regexp_operator_do.json +15 -0
- data/lib/muzang-plugins/muzang-nerdpursuit/questions/ruby/what_is_a_mixin.json +14 -0
- data/lib/muzang-plugins/muzang-plusone.rb +49 -0
- data/lib/muzang-plugins/muzang-reddit.rb +42 -0
- data/lib/muzang-plugins/muzang-rubygems.rb +43 -0
- data/lib/muzang-plugins/version.rb +5 -0
- data/muzang-plugins.gemspec +23 -0
- data/spec/livereload_spec.rb +23 -0
- data/spec/meme_spec.rb +43 -0
- data/spec/motd_spec.rb +18 -0
- data/spec/muzang-eval_spec.rb +43 -0
- data/spec/nerdpursuit_spec.rb +76 -0
- data/spec/plusone_spec.rb +67 -0
- data/spec/reddit_spec.rb +45 -0
- data/spec/rubygems_spec.rb +37 -0
- data/spec/spec_helper.rb +11 -0
- data/spec/support/connection_mock.rb +15 -0
- data/spec/support/responses/meme.response +4 -0
- data/spec/support/responses/reddit.response +3 -0
- data/spec/support/responses/rubygems.response +3 -0
- metadata +259 -0
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "grafix",
|
4
|
+
"nerd_level": 1,
|
5
|
+
"text": "Which image resolution should be used for screen layouts/images?",
|
6
|
+
"a1": "150",
|
7
|
+
"a2": "96",
|
8
|
+
"a3": "100",
|
9
|
+
"a4": "72",
|
10
|
+
"right_answer": "a4",
|
11
|
+
"created_at": "2011-05-24",
|
12
|
+
"created_by": "Schorsch"
|
13
|
+
}
|
14
|
+
}
|
data/lib/muzang-plugins/muzang-nerdpursuit/questions/html/how_do_you_specify_html5_doctyp.json
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
{
|
2
|
+
"question": {
|
3
|
+
"id": "",
|
4
|
+
"category": "html",
|
5
|
+
"nerd_level": 2,
|
6
|
+
"text": "How do you specify HTML5 doctype?",
|
7
|
+
"created_by": "Philipp Brumm",
|
8
|
+
"created_at": "2011-06-14",
|
9
|
+
"right_answer": "a1",
|
10
|
+
"a1": "<!DOCTYPE HTML>",
|
11
|
+
"a2": "<!DOCTYPE HTML5>",
|
12
|
+
"a3": "<!DOCTYPE HTML PUBLIC -//W3C//DTD HTML 5//EN\>",
|
13
|
+
"a4": "<!DOCTYPE NEW HTML 5>"
|
14
|
+
}
|
15
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "html",
|
4
|
+
"nerd_level": 1,
|
5
|
+
"text":"Which attribute can not be forgotten for the <img ../> tag?",
|
6
|
+
"a1": "title",
|
7
|
+
"a2": "border",
|
8
|
+
"a3": "alt",
|
9
|
+
"a4": "width & height",
|
10
|
+
"right_answer":"a3",
|
11
|
+
"created_at": "2011-06-14",
|
12
|
+
"created_by": "Barto"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "html",
|
4
|
+
"nerd_level": 2,
|
5
|
+
"text":"Which one of these tags is not specified as optional according to the HTML 4.01 Strict DTD?",
|
6
|
+
"a1": "<html>",
|
7
|
+
"a2": "</head>",
|
8
|
+
"a3": "<title>",
|
9
|
+
"a4": "<body>",
|
10
|
+
"right_answer":"a3",
|
11
|
+
"created_at": "2011-08-14",
|
12
|
+
"created_by": "Marco"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "html",
|
4
|
+
"nerd_level": 2,
|
5
|
+
"text":"Attribute that is not allowed in Strict DOCTYPE",
|
6
|
+
"a1": "bgcolor",
|
7
|
+
"a2": "name",
|
8
|
+
"a3": "align",
|
9
|
+
"a4": "border",
|
10
|
+
"right_answer":"a1",
|
11
|
+
"created_at": "2011-06-14",
|
12
|
+
"created_by": "Barto"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "http",
|
4
|
+
"nerd_level": 5,
|
5
|
+
"text":"What does the HTCPCP response 418 stand for?",
|
6
|
+
"a1": "Not acceptable",
|
7
|
+
"a2": "I'm a teapot",
|
8
|
+
"a3": "HTCPCP? Nice try.",
|
9
|
+
"a4": "Permanently moved.",
|
10
|
+
"right_answer":"a2",
|
11
|
+
"created_at": "2011-06-07",
|
12
|
+
"created_by": "Philipp"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "javascript",
|
4
|
+
"nerd_level": 5,
|
5
|
+
"text": "Which of this expressions has value 11?",
|
6
|
+
"a1": "+[++[+[]][+[]]+[]+[++[+[]][+[]]]]",
|
7
|
+
"a2": "+[++[+[]][+[]]+[]+[]+[]]",
|
8
|
+
"a3": "[[]+[]+[][+[]]][+[]][++[+[]][+[]]]",
|
9
|
+
"a4": "+[++[+[]][+[]]+[]+[++[+[]][[]]]]",
|
10
|
+
"right_answer": "a1",
|
11
|
+
"created_at": "2011-06-19",
|
12
|
+
"created_by": "Christoph Werner @gonsfx"
|
13
|
+
}
|
14
|
+
}
|
data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/how_can_you_access_the_data_pas.json
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
{
|
2
|
+
"question": {
|
3
|
+
"nerd_level": 5,
|
4
|
+
"text": "How can you access the data passed in with window.history.pushState(data, \"Title\", \"/new-url\") via window.onpopstate event?",
|
5
|
+
"created_by": "Mike Połtyn",
|
6
|
+
"a1": "function () { this }",
|
7
|
+
"a2": "function () { this.state }",
|
8
|
+
"a3": "function (data) { data.state }",
|
9
|
+
"a4": "function (data) { data }",
|
10
|
+
"created_at": "2011-06-14",
|
11
|
+
"category": "javascript",
|
12
|
+
"right_answer": "a3",
|
13
|
+
"id": ""
|
14
|
+
}
|
15
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "javascript",
|
4
|
+
"nerd_level": 4,
|
5
|
+
"text":"Which one is correct JSON?",
|
6
|
+
"a1": "\"name\" : 'Answer'",
|
7
|
+
"a2": "\"name\" : \"Answer\"",
|
8
|
+
"a3": "'name' : 'Answer'",
|
9
|
+
"a4": "'name' : \"Answer\"",
|
10
|
+
"right_answer":"a2",
|
11
|
+
"created_at": "2011-06-07",
|
12
|
+
"created_by": "Philipp"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "javascript",
|
4
|
+
"nerd_level": 4,
|
5
|
+
"text":"What does \"jsonp=?\" or similar statements do?",
|
6
|
+
"a1": "Treat the incoming JSON data as JSONP",
|
7
|
+
"a2": "Tell the server to return JSONP data",
|
8
|
+
"a3": "Tell the server to return JSONP data and wrap it in a dynamic callback",
|
9
|
+
"a4": "Tell the server to return JSONP data and wrap it in a '?' callback",
|
10
|
+
"right_answer":"a2",
|
11
|
+
"created_at": "2011-06-07",
|
12
|
+
"created_by": "Philipp"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "javascript",
|
4
|
+
"nerd_level": 3,
|
5
|
+
"text": "What's the nodeType value of text nodes?",
|
6
|
+
"a1": "1",
|
7
|
+
"a2": "2",
|
8
|
+
"a3": "3",
|
9
|
+
"a4": "4",
|
10
|
+
"right_answer": "a3",
|
11
|
+
"created_at": "2011-08-14",
|
12
|
+
"created_by": "Marco"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "javascript",
|
4
|
+
"nerd_level": 4,
|
5
|
+
"text":"Why can't you just request files from external servers via XMLHttpRequest in a web-browser?",
|
6
|
+
"a1": "XSS",
|
7
|
+
"a2": "Cross-Site Scripting",
|
8
|
+
"a3": "Cross-Domain Scripting",
|
9
|
+
"a4": "Same Origin Policy",
|
10
|
+
"right_answer":"a4",
|
11
|
+
"created_at": "2011-06-07",
|
12
|
+
"created_by": "Philipp"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "javascript",
|
4
|
+
"nerd_level": 4,
|
5
|
+
"text": "Which of these methods is an object run through first on type coercion with a string?",
|
6
|
+
"a1": "toString",
|
7
|
+
"a2": "toObject",
|
8
|
+
"a3": "toPrimitive",
|
9
|
+
"a4": "valueOf",
|
10
|
+
"right_answer": "a3",
|
11
|
+
"created_at": "2011-06-19",
|
12
|
+
"created_by": "Christoph Werner @gonsfx"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "javascript",
|
4
|
+
"nerd_level": 3,
|
5
|
+
"text": "Whats the value of (function() { return typeof arguments; })()?",
|
6
|
+
"a1": "array",
|
7
|
+
"a2": "object",
|
8
|
+
"a3": "undefined",
|
9
|
+
"a4": "arguments",
|
10
|
+
"right_answer": "a2",
|
11
|
+
"created_at": "2011-06-19",
|
12
|
+
"created_by": "Christoph Werner @gonsfx"
|
13
|
+
}
|
14
|
+
}
|
data/lib/muzang-plugins/muzang-nerdpursuit/questions/javascript/valid_function_expression.json
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "javascript",
|
4
|
+
"nerd_level": 4,
|
5
|
+
"text": "Which of these Immediately-Invoked Function Expressions won't give you a NERD-ALERT?",
|
6
|
+
"a1": "~function(){ alert('NERD'); }();",
|
7
|
+
"a2": "0, function(){ alert('NERD'); }();",
|
8
|
+
"a3": ";function(){ alert('NERD'); }();",
|
9
|
+
"a4": "true && function(){ alert('NERD'); }();",
|
10
|
+
"right_answer": "a3",
|
11
|
+
"created_at": "2011-08-14",
|
12
|
+
"created_by": "Marco"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,15 @@
|
|
1
|
+
{
|
2
|
+
"question": {
|
3
|
+
"id": "",
|
4
|
+
"category": "javascript",
|
5
|
+
"nerd_level": 1,
|
6
|
+
"text": "What's '4' + 2?",
|
7
|
+
"created_by": "Marcin Bunsch",
|
8
|
+
"created_at": "2011-06-12",
|
9
|
+
"right_answer": "a1",
|
10
|
+
"a1": "'42'",
|
11
|
+
"a2": "402",
|
12
|
+
"a3": "6",
|
13
|
+
"a4": "0"
|
14
|
+
}
|
15
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{
|
2
|
+
"question": {
|
3
|
+
"id": "",
|
4
|
+
"category": "javascript",
|
5
|
+
"nerd_level": 1,
|
6
|
+
"text": "Who created jQuery?",
|
7
|
+
"created_by": "Marcin Bunsch",
|
8
|
+
"created_at": "2011-06-12",
|
9
|
+
"right_answer": "a2",
|
10
|
+
"a1": "Douglas Crockford",
|
11
|
+
"a2": "John Resig",
|
12
|
+
"a3": "Sam Stephenson"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "php",
|
4
|
+
"nerd_level": 1,
|
5
|
+
"text":"When php was invented?",
|
6
|
+
"a1": "2001",
|
7
|
+
"a2": "2003",
|
8
|
+
"a3": "1995",
|
9
|
+
"a4": "1999",
|
10
|
+
"right_answer":"a3",
|
11
|
+
"created_at": "2011-07-16",
|
12
|
+
"created_by": "Koos"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "python",
|
4
|
+
"nerd_level": 2,
|
5
|
+
"text": "Which one of these statements squares all the numbers in the list l?",
|
6
|
+
"a1": "l.sq_each()",
|
7
|
+
"a2": "[l[i]**2 for i in range(len(l))]",
|
8
|
+
"a3": "[n** * for n in l]",
|
9
|
+
"a4": "lambda l: [n**n for n in l]",
|
10
|
+
"right_answer": "a2",
|
11
|
+
"created_at": "2011-09-15",
|
12
|
+
"created_by": "kragniz"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "rails",
|
4
|
+
"nerd_level": 1,
|
5
|
+
"text":"How many controller actions are created when scaffolding a model e.g. rails generate scaffold User name:string ?",
|
6
|
+
"a1": "6",
|
7
|
+
"a2": "7",
|
8
|
+
"a3": "8",
|
9
|
+
"a4": "9",
|
10
|
+
"right_answer":"a2",
|
11
|
+
"created_at": "2011-06-07",
|
12
|
+
"created_by": "Jost"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "rails",
|
4
|
+
"nerd_level": 2,
|
5
|
+
"text":"How many top-level folders are created in a new Ruby on Rails 3.0 app e.g.: rails new blog ?",
|
6
|
+
"a1": "10",
|
7
|
+
"a2": "11",
|
8
|
+
"a3": "12",
|
9
|
+
"a4": "13",
|
10
|
+
"right_answer":"a2",
|
11
|
+
"created_at": "2011-06-07",
|
12
|
+
"created_by": "Jost"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "rails",
|
4
|
+
"nerd_level": 3,
|
5
|
+
"text": "What's the output of pluralize(2, 'person') ?",
|
6
|
+
"a1": "personperson",
|
7
|
+
"a2": "2 persons",
|
8
|
+
"a3": "2 people",
|
9
|
+
"a4": "2 users",
|
10
|
+
"right_answer": "a3",
|
11
|
+
"created_at": "2011-06-07",
|
12
|
+
"created_by": "tmschndr"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "rails",
|
4
|
+
"nerd_level": 1,
|
5
|
+
"text":"When was Rails first shown to the public?",
|
6
|
+
"a1": "2003",
|
7
|
+
"a2": "2004",
|
8
|
+
"a3": "2005",
|
9
|
+
"a4": "2006",
|
10
|
+
"right_answer":"a2",
|
11
|
+
"created_at": "2011-06-07",
|
12
|
+
"created_by": "Jost"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "culture",
|
4
|
+
"nerd_level": 1,
|
5
|
+
"text":"Who invented Ruby on Rails?",
|
6
|
+
"a1": "The Hanson Brothers",
|
7
|
+
"a2": "David Heinemeier Hansson",
|
8
|
+
"a3": "Han Solo",
|
9
|
+
"a4": "Hans Wurst",
|
10
|
+
"right_answer":"a2",
|
11
|
+
"created_at": "2011-06-07",
|
12
|
+
"created_by": "jhilden"
|
13
|
+
}
|
14
|
+
}
|
@@ -0,0 +1,11 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "rails",
|
4
|
+
"nerd_level": 2,
|
5
|
+
"text":"What does rake about do?",
|
6
|
+
"a1": "List versions of all rails frameworks and the environment",
|
7
|
+
"right_answer":"a1",
|
8
|
+
"created_at": "2011-06-07",
|
9
|
+
"created_by": "Jost"
|
10
|
+
}
|
11
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{ "question" : {
|
2
|
+
"id": "",
|
3
|
+
"category": "rails",
|
4
|
+
"nerd_level": 2,
|
5
|
+
"text": "Which one produces invalid HTML?",
|
6
|
+
"a1": "<p><%= auto_link(text) %></p>",
|
7
|
+
"a2": "<p><%= simple_format(text) %></p>",
|
8
|
+
"a3": "<p><%= highlight(text, word) %></p>",
|
9
|
+
"a4": "<p><%= truncate(text) %></p>",
|
10
|
+
"right_answer": "a2",
|
11
|
+
"created_at": "2011-06-07",
|
12
|
+
"created_by": "tmschndr"
|
13
|
+
}
|
14
|
+
}
|