Social
Table of Contents:
ContactPicker
A button that, when clicked on, displays a list of the contacts to choose among. After the user has made a selection, the following properties will be set to information about the chosen contact:
ContactName
: the contact’s nameEmailAddress
: the contact’s primary email addressEmailAddressList
: a list of the contact’s email addressesContactUri
: the contact’s URI on the devicePhoneNumber
: the contact’s primary phone number (on Later Android Verisons)PhoneNumberList
: a list of the contact’s phone numbers (on Later Android Versions)Picture
: the name of the file containing the contact’s image, which can be used as a Picture property value for the Image or ImageSprite component.
Other properties affect the appearance of the button (TextAlignment
,
BackgroundColor
, etc.) and whether it can be clicked on (Enabled
).
The ContactPicker
component might not work on all phones. For example, on Android systems
before system 3.0, it cannot pick phone numbers, and the list of email addresses will contain
only one email.
Properties
- BackgroundColor
- Specifies the
ContactPicker
’s background color as an alpha-red-green-blue integer. If anImage
has been set, the color change will not be visible until theImage
is removed. - ContactName
- Returns the full name of the selected contact, or the empty string if a name is unavailable.
- ContactUri
- Returns a URI that specifies the location of the contact on the device.
- EmailAddress
- Returns the primary email address of the selected contact, or the empty string if an email address is unavailable.
- EmailAddressList
- Returns a list of email addresses associated with the selected contact.
- Enabled
- Specifies whether the
ContactPicker
should be active and clickable. - FontBold
- Specifies whether the text of the
ContactPicker
should be bold. Some fonts do not support bold. - FontItalic
- Specifies whether the text of the
ContactPicker
should be italic. Some fonts do not support italic. - FontSize
- Specifies the text font size of the
ContactPicker
, measured in sp(scale-independent pixels). - FontTypeface
- Specifies the text font face of the
ContactPicker
as default, serif, sans serif, or monospace. - Height
- Specifies the
ContactPicker
’s vertical height, measured in pixels. - HeightPercent
- Specifies the
ContactPicker
’s vertical height as a percentage of theScreen
’sHeight
. - Image
- Specifies the path of the
ContactPicker
’s image. If there is both anImage
and aBackgroundColor
specified, only theImage
will be visible. - PhoneNumber
- Returns the primary phone number associated with the selected contact, or the empty string if no phone number is associated with the contact.
- PhoneNumberList
- Returns a list of phone numbers associated with the selected contact.
- Picture
- Returns a picture URI for the selected contact, which can be used to retrieve the contact’s photo and other fields.
- Shape
- Specifies the shape of the
ContactPicker
. The valid values for this property are0
(default),1
(rounded),2
(rectangle), and3
(oval). TheShape
will not be visible if anImage
is used. - ShowFeedback
- Specifies if a visual feedback should be shown when a
ContactPicker
with an assignedImage
is pressed. - Text
- Specifies the text displayed by the
ContactPicker
. - TextAlignment
- Specifies the alignment of the
ContactPicker
’s text. Valid values are:0
(normal; e.g., left-justified if text is written left to right),1
(center), or2
(opposite; e.g., right-justified if text is written left to right). - TextColor
- Specifies the text color of the
ContactPicker
as an alpha-red-green-blue integer. - Visible
- Specifies whether the
ContactPicker
should be visible on the screen. Value istrue
if theContactPicker
is showing andfalse
if hidden. - Width
- Specifies the horizontal width of the
ContactPicker
, measured in pixels. - WidthPercent
- Specifies the horizontal width of the
ContactPicker
as a percentage of theScreen
’sWidth
.
Events
- AfterPicking()
- Event to be raised after the
ContactPicker
activity returns its result and the properties have been filled in. - BeforePicking()
- Event to raise when the
ContactPicker
is clicked or the picker is shown using theOpen
method. This event occurs before the picker is displayed, and can be used to prepare the picker before it is shown. - GotFocus()
- Indicates the cursor moved over the
ContactPicker
so it is now possible to click it. - LostFocus()
- Indicates the cursor moved away from the
ContactPicker
so it is now no longer possible to click it. - TouchDown()
- Indicates that the
ContactPicker
was pressed down. - TouchUp()
- Indicates that the
ContactPicker
has been released.
Methods
- Open()
- Opens the
ContactPicker
, as though the user clicked on it. - ViewContact(uri)
- Opens the selected contact’s entry in the device’s default Contacts app.
EmailPicker
An EmailPicker
is a kind of text box. If the user begins entering the name or email address of
a contact, the phone will show a dropdown menu of choices that complete the entry. If there are
many contacts, the dropdown can take several seconds to appear, and can show intermediate
results while the matches are being computed.
The initial contents of the text box and the contents< after user entry is in the Text
property. If the Text
property is initially empty, the contents of the Hint
property will be faintly shown in the text box as a hint to the user.
Other properties affect the appearance of the text box (TextAlignment
,
BackgroundColor
, etc.) and whether it can be used (Enabled
).
Text boxes like this are usually used with Button
components, with
the user clicking on the button when text entry is complete.
Properties
- BackgroundColor
- The background color of the
EmailPicker
`. You can choose a color by name in the Designer or in the Blocks Editor. The default background color is ‘default’ (shaded 3-D look). - Enabled
- If set, user can enter text into the
EmailPicker
. - FontBold
- Specifies whether the text of the
EmailPicker
should be bold. Some fonts do not support bold. - FontItalic
- Specifies whether the text of the
EmailPicker
should be italic. Some fonts do not support italic. - FontSize
- Specifies the text font size of the
EmailPicker
, measured in sp(scale-independent pixels). - FontTypeface
- The text font face of the
EmailPicker
. Valid values are0
(default),1
(serif),2
(sans serif), or3
(monospace). - Height
- Specifies the
EmailPicker
’s vertical height, measured in pixels. - HeightPercent
- Specifies the
EmailPicker
’s vertical height as a percentage of theScreen
’sHeight
. - Hint
EmailPicker
hint for the user.- Text
- The text in the
EmailPicker
, which can be set by the programmer in the Designer or Blocks Editor, or it can be entered by the user (unless theEnabled
property is false). - TextAlignment
- Specifies the alignment of the
EmailPicker
’s text. Valid values are:0
(normal; e.g., left-justified if text is written left to right),1
(center), or2
(opposite; e.g., right-justified if text is written left to right). - TextColor
- Specifies the text color of the
EmailPicker
as an alpha-red-green-blue integer. - Visible
- Specifies whether the
EmailPicker
should be visible on the screen. Value istrue
if theEmailPicker
is showing andfalse
if hidden. - Width
- Specifies the horizontal width of the
EmailPicker
, measured in pixels. - WidthPercent
- Specifies the horizontal width of the
EmailPicker
as a percentage of theScreen
’sWidth
.
Events
- GotFocus()
- Event raised when the
EmailPicker
is selected for input, such as by the user touching it. - LostFocus()
- Event raised when the
EmailPicker
is no longer selected for input, such as if the user touches a different text box.
Methods
- RequestFocus()
- Request focus to current
EmailPicker
.
PhoneCall
A non-visible component that makes a phone call to the number specified in the
PhoneNumber
property, which can be set either in the Designer or Blocks Editor.
The component has a MakePhoneCall
method, enabling the program to launch a phone call.
You may also use MakePhoneCallDirect
to directly initiate a phone call without user
interaction. However, apps using this block may require further review by Google if submitted
to the Play Store so it is advised to use MakePhoneCall
instead.
Often, this component is used with the ContactPicker
component, which lets the user
select a contact from the ones stored on the phone and sets the
PhoneNumber
property to ContactPicker
’s PhoneNumber
property.
To directly specify the phone number (e.g.,<PHONE_NUMBER>), set the PhoneNumber
property to a Text with the specified digits (e.g., “6505551212”). Dashes, dots, and parentheses
may be included (e.g., “(650)-555-1212”) but will be ignored; spaces may not be included.
Properties
- PhoneNumber
- Specifies the phone number to call.
Events
- IncomingCallAnswered(phoneNumber)
- Event indicating that an incoming phone call is answered.
phoneNumber
is the incoming call phone number. - PhoneCallEnded(status,phoneNumber)
- Event indicating that a phone call has ended. The
status
can be any of:1
: Incoming call was missed or rejected2
: Incoming call was answered and hung up3
: Outgoing call was hung up.
- PhoneCallStarted(status,phoneNumber)
- Event indicating that a phone call has started. The
status
can be any of:1
: Incoming call is ringing2
: Outgoing call is dialled
Methods
- MakePhoneCall()
- Launches the default dialer app set to start a phone call using the number in the
PhoneNumber
property. - MakePhoneCallDirect()
- Directly initiates a phone call using the number in the
PhoneNumber
property, bypassing user interaction to start the call. Most apps should useMakePhoneCall
instead, which requires no permissions.
PhoneNumberPicker
A button that, when clicked on, displays a list of the contacts’ phone numbers to choose among. After the user has made a selection, the following properties will be set to information about the chosen contact:
ContactName
: the contact’s namePhoneNumber
: the contact’s phone numberEmailAddress
: the contact’s email addressPicture
: the name of the file containing the contact’s image, which can be used as a Picture property value for the Image or ImageSprite component.
Other properties affect the appearance of the button (TextAlignment
,
BackgroundColor
, etc.) and whether it can be clicked on (Enabled
).
The PhoneNumberPicker
component may not work on all Android devices. For example, on Android
systems before system 3.0, the returned lists of phone numbers and email addresses will be empty.
Properties
- BackgroundColor
- Specifies the
PhoneNumberPicker
’s background color as an alpha-red-green-blue integer. If anImage
has been set, the color change will not be visible until theImage
is removed. - ContactName
- Returns the full name of the selected contact, or the empty string if a name is unavailable.
- ContactUri
- Returns a URI that specifies the location of the contact on the device.
- EmailAddress
- Returns the primary email address of the selected contact, or the empty string if an email address is unavailable.
- EmailAddressList
- Returns a list of email addresses associated with the selected contact.
- Enabled
- Specifies whether the
PhoneNumberPicker
should be active and clickable. - FontBold
- Specifies whether the text of the
PhoneNumberPicker
should be bold. Some fonts do not support bold. - FontItalic
- Specifies whether the text of the
PhoneNumberPicker
should be italic. Some fonts do not support italic. - FontSize
- Specifies the text font size of the
PhoneNumberPicker
, measured in sp(scale-independent pixels). - FontTypeface
- Specifies the text font face of the
PhoneNumberPicker
as default, serif, sans serif, or monospace. - Height
- Specifies the
PhoneNumberPicker
’s vertical height, measured in pixels. - HeightPercent
- Specifies the
PhoneNumberPicker
’s vertical height as a percentage of theScreen
’sHeight
. - Image
- Specifies the path of the
PhoneNumberPicker
’s image. If there is both anImage
and aBackgroundColor
specified, only theImage
will be visible. - PhoneNumber
- Returns the primary phone number associated with the selected contact, or the empty string if no phone number is associated with the contact.
- PhoneNumberList
- Returns a list of phone numbers associated with the selected contact.
- Picture
- Returns a picture URI for the selected contact, which can be used to retrieve the contact’s photo and other fields.
- Shape
- Specifies the shape of the
PhoneNumberPicker
. The valid values for this property are0
(default),1
(rounded),2
(rectangle), and3
(oval). TheShape
will not be visible if anImage
is used. - ShowFeedback
- Specifies if a visual feedback should be shown when a
PhoneNumberPicker
with an assignedImage
is pressed. - Text
- Specifies the text displayed by the
PhoneNumberPicker
. - TextAlignment
- Specifies the alignment of the
PhoneNumberPicker
’s text. Valid values are:0
(normal; e.g., left-justified if text is written left to right),1
(center), or2
(opposite; e.g., right-justified if text is written left to right). - TextColor
- Specifies the text color of the
PhoneNumberPicker
as an alpha-red-green-blue integer. - Visible
- Specifies whether the
PhoneNumberPicker
should be visible on the screen. Value istrue
if thePhoneNumberPicker
is showing andfalse
if hidden. - Width
- Specifies the horizontal width of the
PhoneNumberPicker
, measured in pixels. - WidthPercent
- Specifies the horizontal width of the
PhoneNumberPicker
as a percentage of theScreen
’sWidth
.
Events
- AfterPicking()
- Event to be raised after the
PhoneNumberPicker
activity returns its result and the properties have been filled in. - BeforePicking()
- Event to raise when the
PhoneNumberPicker
is clicked or the picker is shown using theOpen
method. This event occurs before the picker is displayed, and can be used to prepare the picker before it is shown. - GotFocus()
- Indicates the cursor moved over the
PhoneNumberPicker
so it is now possible to click it. - LostFocus()
- Indicates the cursor moved away from the
PhoneNumberPicker
so it is now no longer possible to click it. - TouchDown()
- Indicates that the
PhoneNumberPicker
was pressed down. - TouchUp()
- Indicates that the
PhoneNumberPicker
has been released.
Methods
- Open()
- Opens the
PhoneNumberPicker
, as though the user clicked on it. - ViewContact(uri)
- Opens the selected contact’s entry in the device’s default Contacts app.
Sharing
Sharing is a non-visible component that enables sharing files and/or messages between your app and other apps installed on a device. The component will display a list of the installed apps that can handle the information provided, and will allow the user to choose one to share the content with, for instance a mail app, a social network app, a texting app, and so on.
The file path can be taken directly from other components such as the
Camera
or the ImagePicker
, but can also be
specified directly to read from storage. Be aware that different devices treat storage
differently, so a few things to try if, for instance, you have a file called arrow.gif
in the
folder Appinventor/assets
, would be:
"file:///sdcard/Appinventor/assets/arrow.gif"
; or"/storage/Appinventor/assets/arrow.gif"
Properties
None
Events
None
Methods
- Shares a file through any capable application installed on the phone by displaying a list of the available apps and allowing the user to choose one from the list. The selected app will open with the file inserted on it.
- Shares both a file and a message through any capable application installed on the phone by displaying a list of available apps and allowing the user to choose one from the list. The selected app will open with the file and message inserted on it.
- Shares a message through any capable application installed on the phone by displaying a list of the available apps and allowing the user to choose one from the list. The selected app will open with the message inserted on it.
Texting
A component that will, when the SendMessage
method is called, launch the device’s
preferred texting app to send the text message specified in the SendMessage
property
to the phone number specified in the PhoneNumber
property. You may also send text
messages without user interaction by calling SendMessageDirect
instead, but this
adds dangerous permissions to your final app.
If the ReceivingEnabled
property is set to 1 messages will not be received. If
ReceivingEnabled
is set to 2 messages will be received only when the application is
running. Finally if ReceivingEnabled
is set to 3, messages will be received when the
application is running and when the application is not running they will be queued and a
notification displayed to the user.
When a message arrives, the MessageReceived
event is raised and
provides the sending number and message.
An app that includes this component will receive messages even when it is in the background (i.e. when it’s not visible on the screen) and, moreso, even if the app is not running, so long as it’s installed on the phone. If the phone receives a text message when the app is not in the foreground, the phone will show a notification in the notification bar. Selecting the notification will bring up the app. As an app developer, you’ll probably want to give your users the ability to control ReceivingEnabled so that they can make the phone ignore text messages.
If the GoogleVoiceEnabled
property is true, messages can be sent over Wifi using
Google Voice. This option requires that the user have a Google Voice account and that the mobile
Voice app is installed on the phone. The Google Voice option works only on phones that support
Android 2.0 (Eclair) or higher. Unfortunately, receiving no longer works in Google Voice due to
changes introduced in Google Voice App.
To specify the phone number (e.g.,<PHONE_NUMBER>), set the PhoneNumber property to a Text string with the specified digits (e.g.,<PHONE_NUMBER>). Dashes, dots, and parentheses may be included (e.g.,<PHONE_NUMBER>) but will be ignored; spaces may not be included.
Another way for an app to specify a phone number would be to include a PhoneNumberPicker
component, which lets the users select a phone numbers from the ones stored in the the phone’s
contacts.
Properties
- GoogleVoiceEnabled
- If this property is true, then SendMessage will attempt to send messages over WiFi, using Google voice.
- Message
- The message that will be sent when the
SendMessage
method is called. The maximum length of a standard SMS message is usually 170. It may be less for languages using diacritical marks. - PhoneNumber
- The number that the message will be sent to when the SendMessage method is called. The number is a text string with the specified digits (e.g.,<PHONE_NUMBER>). Dashes, dots, and parentheses may be included (e.g.,<PHONE_NUMBER>) but will be ignored; spaces should not be included.
- ReceivingEnabled
- If set to 1 (OFF) no messages will be received. If set to 2 (FOREGROUND) or 3 (ALWAYS) the
component will respond to messages if it is running. In the case of 2 (FOREGROUND), messages
received while the app is not running are discarded. In the case of 3 (ALWAYS), messages
receive while the app is not running will show a notification. Selecting the notification
will bring up the app and signal the
MessageReceived
event. Messages received when the app is dormant will be queued, and so severalMessageReceived
events might appear when the app awakens. As an app developer, it would be a good idea to give your users control over this property, so they can make their phones ignore text messages when your app is installed.
Events
- MessageReceived(number,messageText)
- Event that’s raised when a text message is received by the phone. Using this block will add dangerous permissions that will require additional approval if your app is submitted to the Google Play Store.
Methods
- SendMessage()
- Launch the phone’s default text messaging app with the message and phone number prepopulated.
- SendMessageDirect()
- Send a text message. Using this block will add dangerous permissions that will require additional approval if your app is submitted to the Google Play Store.
A non-visible component that enables communication with Twitter. Once a
user has logged into their Twitter account (and the authorization has been confirmed successful
by the IsAuthorized
event), many more operations are available:
- Searching Twitter for tweets or labels (
SearchTwitter
) - Sending a Tweet (
Tweet
) - Sending a Tweet with an Image (
TweetWithImage
) - Directing a message to a specific user (
DirectMessage
) - Receiving the most recent messages directed to the logged-in user (
RequestDirectMessages
) - Following a specific user (
Follow
) - Ceasing to follow a specific user (
StopFollowing
) - Getting a list of users following the logged-in user (
RequestFollowers
) - Getting the most recent messages of users followed by the logged-in user (
RequestFriendTimeline
) - Getting the most recent mentions of the logged-in user (
RequestMentions
)
You must obtain a Consumer Key and Consumer Secret for Twitter authorization specific to your app from http://twitter.com/oauth_clients/new
Properties
- ConsumerKey
- The consumer key to be used when authorizing with Twitter via OAuth.
- ConsumerSecret
- The consumer secret to be used when authorizing with Twitter via OAuth.
- DirectMessages
- This property contains a list of the most recent messages mentioning the logged-in user.
Initially, the list is empty. To set it, the program must:
- Call the
Authorize
method. - Wait for the
IsAuthorized
event. - Call the
RequestDirectMessages
method. 4, Wait for theDirectMessagesReceived
event.
The value of this property will then be set to the list of direct messages retrieved (and maintain that value until any subsequent call to
RequestDirectMessages
). - Call the
- Followers
- This property contains a list of the followers of the logged-in user. Initially, the list is
empty. To set it, the program must:
- Call the
Authorize
method. - Wait for the
IsAuthorized
event. - Call the
RequestFollowers
method. - Wait for the
FollowersReceived
event.
The value of this property will then be set to the list of followers (and maintain its value until any subsequent call to
RequestFollowers
). - Call the
- FriendTimeline
- This property contains the 20 most recent messages of users being followed. Initially, the
list is empty. To set it, the program must:
- Call the
Authorize
method. - Wait for the
IsAuthorized
event. - Specify users to follow with one or more calls to the
Follow
method. - Call the
RequestFriendTimeline
method. - Wait for the
FriendTimelineReceived
event.
The value of this property will then be set to the list of messages (and maintain its value until any subsequent call to
RequestFriendTimeline
. - Call the
- Mentions
- This property contains a list of mentions of the logged-in user. Initially, the list is empty.
To set it, the program must:
- Call the
Authorize
method. - Wait for the
IsAuthorized
event. - Call the
RequestMentions
method. - Wait for the
MentionsReceived
event.
The value of this property will then be set to the list of mentions (and will maintain its value until any subsequent calls to
RequestMentions
). - Call the
- SearchResults
- This property, which is initially empty, is set to a list of search results after the program:
- Calls the
SearchTwitter
method. - Waits for the
SearchSuccessful
event.
The value of the property will then be the same as the parameter to
SearchSuccessful
. Note that it is not necessary to call theAuthorize
method before callingSearchTwitter
. - Calls the
- Username
- The user name of the authorized user. Empty if there is no authorized user.
Events
- DirectMessagesReceived(messages)
- This event is raised when the recent messages requested through
RequestDirectMessages
have been retrieved. A list of the messages can then be found in themessages
parameter or theDirectMessages
property. - FollowersReceived(followers2)
- This event is raised when all of the followers of the logged-in user requested through
RequestFollowers
have been retrieved. A list of the followers can then be found in thefollowers
parameter or theFollowers
property. - FriendTimelineReceived(timeline)
- This event is raised when the messages requested through
RequestFriendTimeline
have been retrieved. Thetimeline
parameter and theFriendTimeline
property will contain a list of lists, where each sub-list contains a status update of the form (username message). - IsAuthorized()
- This event is raised after the program calls
Authorize
if the authorization was successful. It is also called after a call toCheckAuthorized
if we already have a valid access token. After this event has been raised, any other method for this component can be called. - MentionsReceived(mentions)
- This event is raised when the mentions of the logged-in user requested through
RequestMentions
have been retrieved. A list of the mentions can then be found in thementions
parameter or theMentions
property. - SearchSuccessful(searchResults)
- This event is raised when the results of the search requested through
SearchTwitter
have been retrieved. A list of the results can then be found in theresults
parameter or theSearchResults
property.
Methods
- Authorize()
- Redirects user to login to Twitter via the Web browser using the OAuth protocol if we don’t already have authorization.
- CheckAuthorized()
- Check whether we already have access, and if so, causes the
IsAuthorized
event handler to be called. - DeAuthorize()
- Removes Twitter authorization from this running app instance.
- DirectMessage(user,message)
- This sends a direct (private) message to the specified user. The message will be trimmed if it
exceeds 160 characters.
Requirements: This should only be called after the
IsAuthorized
event has been raised, indicating that the user has successfully logged in to Twitter. - Follow(user)
- Starts following a user.
- RequestDirectMessages()
- Requests the 20 most recent direct messages sent to the logged-in user. When the messages have
been retrieved, the system will raise the
DirectMessagesReceived
event and set theDirectMessages
property to the list of messages.Requirements: This should only be called after the
IsAuthorized
event has been raised, indicating that the user has successfully logged in to Twitter. - RequestFollowers()
- Gets who is following you.
- RequestFriendTimeline()
- Gets the most recent 20 messages in the user’s timeline.
- RequestMentions()
- Requests the 20 most recent mentions of the logged-in user. When the mentions have been
retrieved, the system will raise the
MentionsReceived
event and set theMentions
property to the list of mentions.Requirements: This should only be called after the
IsAuthorized
event has been raised, indicating that the user has successfully logged in to Twitter. - SearchTwitter(query)
- This searches Twitter for the given String query.
Requirements: This should only be called after the
IsAuthorized
event has been raised, indicating that the user has successfully logged in to Twitter. - StopFollowing(user)
- Stops following a user.
- Tweet(status)
- This sends a tweet as the logged-in user with the specified Text, which will be trimmed if it
exceeds 160 characters.
Requirements: This should only be called after the
IsAuthorized
event has been raised, indicating that the user has successfully logged in to Twitter. - TweetWithImage(status,imagePath)
- This sends a tweet as the logged-in user with the specified Text and a path to the image to be
uploaded, which will be trimmed if it exceeds 160 characters. If an image is not found or
invalid, the update will not be sent.
Requirements: This should only be called after the
IsAuthorized
event has been raised, indicating that the user has successfully logged in to Twitter.


Totally Trivial Trivia!
Time Remaining:
Start Game
What was the first full-length CGI movie?
A Bug's Life
Monster's Inc.
Toy Story
Lion King
Which of these is NOT a name of one of the Spice Girls?
Sporty Spice
Fred Spice
Scary Spice
Posh Spice
Which NBA team won the most titles in the 90s?
New York Knicks
Portland Trailblazers
Los Angeles Lakers
Chicago Bulls


Finite Automata
Disclaimers / Instructions:
- The path always starts with the lowest alphabet
- To add link: Click the first state and then the second state, then click add link below
- To remove state: Click the state for 2 seconds
- To remove link: Double click the link
Test Results:
Accepted
Rejected


Holiday Gift Guide 2019: The Best Backpacks For Every Kind Of Traveler
by Lois Alter MarkRemember when backpacks used to be worn only by hikers? Now, they’re the bag of choice for businesspeople, students, fitness enthusiasts and, especially, travelers.
Here are the ones that are elevating – and, in some cases redefining – the category. With these backpacks, stylish, easy travel is in the bag.
There’s a reason Away has such a loyal following: their bags are pretty much perfect. This compact Daypack has a streamlined profile that holds everything you need neatly and easy to access. Its straps are cushy enough to spend the day on your shoulders, and its sleeve slides smoothly on to your favorite Away luggage. It’s just another reason to go Away. Price: $145
This handcrafted leather backpack is so luxurious, you’ll want to show it off everywhere. Ghurka is a favorite of A-listers like Tom Hanks and LeBron James, and you’ll feel like one yourself, especially since every piece comes with its own unique registration tag. The bag is equipped with a padded laptop holder and a nine-inch interior zipper pouch to keep your belongings safe and secure. In Vintage Chestnut Leather, it just gets better with age. Price: $1,295
This beauty’s good looks belie its practicality. Lightweight and durable, it’s available in Olive, Deep Lake and Black nylon, and features a padded laptop compartment and tablet pocket as well as an organizational panel with dedicated pockets for your essentials. Simple and stylish, this backpack means business. Price: $179
If you want a backpack that truly stands out, Cotopaxi has created an entire collection made from repurposed fabric, ensuring that every brightly-colored piece is one-of-a-kind. You can choose the exact bag you want or let Cotopaxi surprise you. Either way, you will treasure this rugged, thoughtfully-designed, feature-filled backpack meant for adventure. Price: $180
Made specifically for creatives by creatives, Osuza takes the idea of a backpack and totally twists it and turns it into a whole new bag. This premium black canvas bag is expandable, weatherproof and customizable. Best of all, it opens flat so you can access all your well-organized tools. If only your creativity and inspiration could last as long as Osuza’s lifetime warranty. Price: $349
Pretty in Mauve (or Buttermilk or Black), this light as air backpack will just make you happy. Everything you need stays safely cuddled in cloud-like puffiness while the waterproof nylon keeps it all dry.  Built-in phone and battery pockets keep you powered up, Price: $225
Sleek and sophisticated, this backpack from beloved luggage maker Briggs & Riley has three sections to keep you organized. There are separate pockets for tablets, cables and chargers, cords and USB drives and there’s even an RFID blocking pocket with two hidden credit card slip pockets to protect your personal data. The whole bag perfectly represents the band’s philosophy: engineered for reality. Price: $319
This super-light ripstop nylon backpack may weigh a mere 14 ounces but it is actually a powerhouse that can hold 100 pounds of your most important stuff. It’s got lots of pockets, including an internal stow pocket you can smush it into for travel and two side ones with new loop locks to keep water bottles secure. It’s also got a “Blinky” loop for attaching a light to help keep you visible because you’re likely to want to stay out late, now that you can comfortably carry around everything you need. Price: $49.95
Celebrate the coolest mom with this beautiful backpack, which also happens to be a diaper bag and changing station. Made from 100% recycled plastics, it features cushioned straps, easy access to everything inside and out plus a padded laptop sleeve for mama multitasking. It looks so good, you may want to use it even if you don’t have babies. Price: $180
Incase may be driven by design but their ICON backpack is an organizational wonder. Made of lightweight yet durable Woolenex to repel moisture, mildew and chemicals, it has a designated place for everything from papers to tech accessories to your laptop. Padded shoulder straps adjust for optimal comfort and ergonomic support, and there’s a cable port – just Incase. Price: $199.95
CamelBak is all about hands-free hydration, and the Rim Runner has long been a bestseller for day hikers. It offers a clean aesthetic and cargo pockets that let you grab what you need without removing your pack. The new Crux reservoir holds 2.5 liters, delivers 20% more water per sip, along with an ergonomic handle for easy refilling and an on/off lever to prevent leaks. This is definitely the bag to quench your thirst. Price: $100
Handmade in an ethical factory in León, Mexico, this rich leather backpack has so much character, it will become a cherished possession. It’s lined with tan cotton canvas, and features an interior laptop pocket and exterior front zip compartment. The leather pulls on the double zippers add sophisticated detailing to an already classic design. Price: $268
Likely to become your everyday go-to, this nylon backpack effortlessly takes you from work to the gym to the airport in style. It has compartments and zippers for everything from your laptop to a change of clothes to shoes – which fit into their own zippered space at the bottom of the bag. As if all that weren’t enough, for every State bag purchased, the company helps American children and families in need as part of their Give. Back. Pack. Initiative. Price: $165
This amazing carry-on lets you keep your hands-free by doubling as a backpack. Durable and water-resistant, it features more than 20 practical features including a magnetic snap water bottle pocket, a mesh divider to separate your clothes from your electronics and a TSA-approved laptop pocket. It’s literally the only bag you need for a long weekend away. Price: $269.99
Soft and roomy, the Kenzie even comes with a detachable shoulder strap so you can change it up for different outfits. This bestselling vegan leather backpack is so versatile, you’ll want one in every color. Because it’s so well-priced, you just might be able to give in to temptation. Price: $52
This is not your mother’s diaper bag! In fact, you would never guess that’s what it was because it’s so fashion-forward, made of premium vegan leather and adorned with antique hardware and zippers. Yet there are a dozen pockets to hold everything from bottles and toys to diapers and wipes. Yeah, baby. Price: $169.99
Made in Italy, this classic leather backpack has a polished look that opens to an unexpected red fabric lining. Its beautiful stitching and detailing are simple yet statement-making, and are signature Paul Stuart, which says everything you need to know and why you’ll want it. Price: $550


write(LineChart(chart_data))
write("Line Chart (detailed API)", fmt="header", level=4)
write(Chart(chart_data, "line_chart")
.x_axis()
.y_axis()
.cartesian_grid(stroke_dasharray="3 3")
import urllib, io
import sys
sys.path.append("local/server")
from streamlit import Notebook, Chart, LineChart, AreaChart, BarChart
with Notebook() as write:
// Title.


It’s bad tech etiquette to take other peoples’ phone chargers
The unofficial guide to tech etiquette
by Mariya AbdulkafTechnology turns people into weird creatures — and not the Instagram filter kind. It breeds gross behavior, like texting on the toilet, or tempts you into swiping through somebody’s entire camera roll when they show you just one picture.
Since there’s no official manual to tech etiquette and everyone has their own opinions, we’re launching an animated series documenting our personal tech peeves. Will airing these out finally put an end to one-word, no punctuation “hey” messages? Or stop your grandmother from sending her entire email message in the subject line? Maybe. Or maybe not.
Our new series Tech Etiquette is about calling people out the weird, quirky, and sometimes infuriating things humans do with technology. May these personal confessions be the unofficial guide to tech etiquette we all need.
Nothing inspired this series more than working in an open office where your phone charger is up for grabs to literally anyone within reach.
The first episode is all about these lawless creatures.
Let us know in the comments: what are some of your biggest tech peeves?


When time to market has not necessarily been a factor, good reusable products resulted:
- ACE (Doug Schmidt)
- util.concurrent (Doug Lea)
- RSA JSAFE security products


JAMHacks 2 is Waterloo's biggest high school hackathon! On April 14-15, we are bringing together 200 students from high schools all over Ontario for a full weekend of creating, learning and innovating. Participants ("hackers") will get the entire 24 hours to invent and build a software or hardware project, and then show it off to a panel of judges as well as their fellow hackers.
As a high school hackathon, our mission is to inspire more high school students to explore and pursue truly innovative projects and careers in technology. With your help, we can show them firsthand why Waterloo is internationally recognized for innovation.
Connect with young computer scientists. For many participants, JAMHacks will be their first hackathon, a special and unforgettable experience. This is a unique opportunity for you to make an early impression on our participants.
Branding and Exposure. You will be recognised for supporting the next generation of developers and makers. Additionally, if you bring your API or product, participants will get firsthand experience with your product and are likely to continue using it in the future.
Recruit. We are gathering Waterloo Region's brightest and most talented young developers and engineers into one place, and giving them a perfect environment to demonstrate their skills. See the available perks for recruiting below, or contact us—Everything is negotiable.
Note: Monetary contributions are tax deductible through the Waterloo Education Foundation Inc., a registered charitable foundation which is part of the Waterloo Region District School Board.
In April 2017, we hosted JAMHacks, Waterloo's first hackathon organized entirely by high school students, for high school students. Over 100 students, some from as far as Toronto, Mississauga and Windsor, came out for the 12-hour event. Even in such a short amount of time, our hackers created a wide array of impressive projects, such as a physical light-up chessboard.
| Sponsorship Tiers | Peach | Grape | Strawberry | Blueberry (Co-Host)* | ||
| Amount (or equivalent goods/services) | $500 | $1000 | $2000 | $4000 | ||
| Your Branding | ||||||
| Logo on Website and T-Shirts | Small | Medium | Large | Huge | ||
| Distribute Swag | ✔ | ✔ | ✔ | ✔ | ||
| Thanked at Opening Ceremony | ✔ | ✔ | ✔ | ✔ | ||
| Shout-outs on Social Media | ✔ | ✔ | ✔ | |||
| Logo on Posters and Other Promotional Material | ✔ | ✔ | ||||
| JAMHacks, Co-Hosted by [You] | ✔ | |||||
| Your Involvement | ||||||
| Send Mentors/Evangelists | Max. 2 | Max. 4 | Unlimited | Unlimited | ||
| Sponsor Booth | ✔ | ✔ | ✔ | |||
| Company Judge | ✔ | ✔ | ||||
| Direct Involvement in Planning | ✔ | |||||
| Remarks at Closing Ceremony | ✔ | |||||
| Your Products | ||||||
| Demo or Talk at Opening Ceremony | Short (2 min)** |
Short (2 min) |
Long (5 min) |
|||
| Run a Workshop | ✔ (Pick one) | ✔ | ||||
| Custom Award (ex. API Prize) | ✔ | |||||
| Recruiting | ||||||
| Distribute Recruiting Material | ✔ | ✔ | ✔ | |||
| Access to Resumes and GitHub/LinkedIn Profiles | Post-event | Post-event | Pre-event | |||
| Send Email to All Participants | ✔ | ✔ |
* Maximum 1 sponsor at Blueberry tier.
A mentor is a great way to interact with and gain recognition among hackers. The people and companies that will be remembered most by hackers will be those who helped them through any roadblocks and bugs they encounter, and guided them to success.
Your booth is your company's physical representation at our hackathon. We recommend that you send at least one representative (mentor/evangelist) from your company who can tell hackers about your company and answer their questions. To best utilize your space, we recommend providing swag (pens, notepads, stickers, stress balls, t-shirts, etc.) for attendees to pick up when they visit your booth.
You or a representative from your company will have the opportunity to see all of the projects and help select the winners (including the winner of your custom award if you choose to provide one)! We recommend that judges have some background in technology or entrepreneurship to provide the best possible judging for our event.
By hosting a workshop or "tech talk", you can educate our hackers and promote your company's image at the same time! You could teach hackers how to use your product, teach a general skill, or discuss technology or entrepreneurship.
This could be an API prize ("Best use of [Your API]"), or it could be a more general prize, like "Best Hardware Hack" or "Best Environmental Impact Hack". You will provide the reward but we will credit the value of your reward (cash value or equivalent retail value) towards your sponsorship contribution, up to a maximum of $1000. If you wish to provide an intangible reward, we can discuss how to credit it towards your sponsorship.
Send us an email at<EMAIL_ADDRESS>All sponsorships are negotiable and we would be more than happy to discuss details, or work out a custom sponsorship opportunity for you!


Please follow the Instructions below to upload documents on Epic:
Click the "More Activities" button on the bottom left of the patient's chart on Epic
Click "Media Manager"
On the new window that opens up, click "Import"
Find the file you would like to upload. You will need to find the file manually (i.e. go to "Computer", then "C:", then to the folder where you stored the file when you uploaded it). The Documents/Pictures/Music folders on the left do not correspond to the same folders on your workstation.
Enter the name of the document, the type of document it is, and who you would like to get a notification that the document has been uploaded (usually the clinic team).
Click the accept button at the very bottom of the screen. You might need to resize your windows a little bit go find it.


{% extends "cfp/event/base.html" %} {% load bootstrap4 %} {% load i18n %} {% block title %}{% translate "Login" %} :: {% endblock %} {% block content %}
{% blocktranslate trimmed %} You do not need an account to view the event, or submit feedback, or receive schedule updates. You'll only need an account if you participate in the event as speaker or as an organiser. {% endblocktranslate %}
{% blocktranslate trimmed %} If you already created a proposal for a different event on this server, you can re-use your account to log in for this event. {% endblocktranslate %}
{% include "common/auth.html" %} {% endblock %}


Part of pymine.beautifulsoup.BeautifulSoup View In Hierarchy
Known subclasses: pymine.beautifulsoup.BeautifulSoup.BeautifulStoneSoup
| Method | _invert | Cheap function to invert a hash. |
| Method | _convertEntities | Used in a call to re.sub to replace HTML, XML, and numeric |
| Method | __init__ | Basic constructor. |
| Method | getString | Undocumented |
| Method | setString | Replace the contents of the tag with a string |
| Method | getText | Undocumented |
| Method | get | Returns the value of the 'key' attribute for the tag, or |
| Method | clear | Extract all children. |
| Method | index | Undocumented |
| Method | has_key | Undocumented |
| Method | __getitem__ | tag[key] returns the value of the 'key' attribute for the tag, |
| Method | __iter__ | Iterating over a tag iterates over its contents. |
| Method | __len__ | The length of a tag is the length of its list of contents. |
| Method | __contains__ | Undocumented |
| Method | __nonzero__ | A tag is non-None even if it has no contents. |
| Method | __setitem__ | Setting tag[key] sets the value of the 'key' attribute for the |
| Method | __delitem__ | Deleting tag[key] deletes all 'key' attributes for the tag. |
| Method | __call__ | Calling a tag like a function is the same as calling its |
| Method | __getattr__ | Undocumented |
| Method | __eq__ | Returns true iff this tag has the same name, the same attributes, |
| Method | __ne__ | Returns true iff this tag is not identical to the other tag, |
| Method | __repr__ | Renders this tag as a string. |
| Method | __unicode__ | Undocumented |
| Method | _sub_entity | Used with a regular expression to substitute the |
| Method | __str__ | Returns a string or Unicode representation of this tag and |
| Method | decompose | Recursively destroys the contents of this tree. |
| Method | prettify | Undocumented |
| Method | renderContents | Renders the contents of this tag as a string in the given |
| Method | find | Return only the first child of this Tag matching the given |
| Method | findAll | Extracts a list of Tag objects that match the given |
| Method | fetchText | Undocumented |
| Method | firstText | Undocumented |
| Method | _getAttrMap | Initializes a map representation of this tag's attributes, |
| Method | childGenerator | Undocumented |
| Method | recursiveChildGenerator | Undocumented |
Inherited from PageElement:
| Method | setup | Sets up the initial relations between this element and |
| Method | replaceWith | Undocumented |
| Method | replaceWithChildren | Undocumented |
| Method | extract | Destructively rips this element out of the tree. |
| Method | _lastRecursiveChild | Finds the last element beneath this object to be parsed. |
| Method | insert | Undocumented |
| Method | append | Appends the given tag to the contents of this tag. |
| Method | findNext | Returns the first item that matches the given criteria and |
| Method | findAllNext | Returns all items that match the given criteria and appear |
| Method | findNextSibling | Returns the closest sibling to this Tag that matches the |
| Method | findNextSiblings | Returns the siblings of this Tag that match the given |
| Method | findPrevious | Returns the first item that matches the given criteria and |
| Method | findAllPrevious | Returns all items that match the given criteria and appear |
| Method | findPreviousSibling | Returns the closest sibling to this Tag that matches the |
| Method | findPreviousSiblings | Returns the siblings of this Tag that match the given |
| Method | findParent | Returns the closest parent of this Tag that matches the given |
| Method | findParents | Returns the parents of this Tag that match the given |
| Method | _findOne | Undocumented |
| Method | _findAll | Iterates over a generator looking for things that match. |
| Method | nextGenerator | Undocumented |
| Method | nextSiblingGenerator | Undocumented |
| Method | previousGenerator | Undocumented |
| Method | previousSiblingGenerator | Undocumented |
| Method | parentGenerator | Undocumented |
| Method | substituteEncoding | Undocumented |
| Method | toEncoding | Encodes an object to a string in some encoding, or to Unicode. |
NOTE: right now this will return false if two tags have the same attributes in a different order. Should this be fixed?
NOTE: since Python's HTML parser consumes whitespace, this method is not certain to reproduce the whitespace present in the original string.
The value of a key-value pair in the 'attrs' map can be a string, a list of strings, a regular expression object, or a callable that takes a string and returns whether or not the string matches for some custom definition of 'matches'. The same is true of the tag name.


Mahindra
Engine
Dimension
Comfort
Safety
The Mahindra Scorpio is a four-wheel drive compact SUV manufactured by Mahindra & Mahindra Limited, the flagship company of the Indian Mahindra Group. It was the first SUV from the company built for a global market. The Scorpio has been successfully accepted in international markets across the globe, and will shortly be launched in the United States.
The Scorpio was conceptualized and designed by the in-house integrated design and manufacturing team of M&M. The car has been the recipient of t
Etsy mixtape wayfarers, ethical wes anderson tofu before they sold out mcsweeney's organic lomo retro fanny pack lo-fi farm-to-table readymade. Messenger bag gentrify pitchfork tattooed craft beer, iphone skateboard locavore carles etsy salvia banksy hoodie helvetica. DIY synth PBR banksy irony. Leggings gentrify squid 8-bit cred pitchfork.
 Fanny pack portland seitan DIY, art party locavore wolf cliche high life echo park Austin. Cred vinyl keffiyeh DIY salvia PBR, banh mi before they sold out farm-to-table VHS viral locavore cosby sweater.
Jai Motors
- Chennai
-<EMAIL_ADDRESS>-<PHONE_NUMBER>


The movie is a powerful and disturbing drama about prejudice, its consequences and family.
 Much of the movie is shot in close-up, so you can look these people in the eyes.
The drama centers around two brothers, Derek (Edward Norton) and Danny (Edward Furlong). The story is narrated by Danny, who idolizes his older brother.
Derek, following the death of his firefighting father - who was shot while battling a blaze at a crack house - succumbs to a philosophy of hate and is transformed into a charismatic leader of a white power movement.
Derek is sent to prison for murder. There, he goes through a process of self-discovery, realizing that what he thought he knew and what he was taught by Cameron (Stacy Keach), the behind-the-scenes manipulator of the skinheads, is bogus.
Released from prison after three years, Derek arrives home and finds Danny starting to trod Derek's old path - hanging around with Cameron and the other skinhead losers.
Derek works to dissuade Danny from that life of hatred, trying to convince him of the lies and intolerance spewed by Cameron.
Danny, meanwhile, must rewrite a school paper for his history class because the one he wrote on Mein Kampf - at Cameron's urging - was rejected. The principal orders him to write about Derek, how he feels about him and the events leading to Derek's incarceration.
Through this process, and through talks with Derek, Danny slowly comes to realize the truth - that the venom spewed by Cameron and his ilk creates nothing but misery.
Kaye and screenwriter David McKenna spare no one as the sins of one brother are visited upon the other.
Many disturbing scenes, especially the trashing of a Korean-owned grocery story, will leave you breathless in their mindless violence.
Norton gives a powerful performance, his best since his stunning debut in Primal Fear. He shows Derek's intelligence, his charisma and his commitment, both to the cause to which he thought he believed and, after his release from prison, his resolve to extract his brother from the ill-fated path he followed.
Norton's performance is of Academy-Award caliber.
Furlong, best remembered as young John Conner from Terminator 2: Judgment Day, brings a sense of confusion mixed with adulation to his role as the impressionable younger brother.
With his skinhead haircut and slit-eyed glance, one can see the virus of hate planted in the boy begin to grow. When Danny is around Derek, his entire posture changes. He is more the young, adoring brother hanging on every word said by his older sibling.
There is a powerful moment when the brothers take down all the hate literature and Nazi paraphernalia hanging in their bedroom. No words are needed. Their actions say it all.
Later, Derek stares long and hard at the large, black swastika tattooed over his heart, with a look combining regret and shame. Again, without a word, Derek places his hand over his heart in order to obliterate the foul reminder of his past life.
K aye has gathered a rather impressive cast. Keach, as Cameron, is, in Derek's words, "a chicken hawk," preying on young dissatisfied minds to convert to his cause, sending them out to do his dirty work while he stays in the shadows. Keach speaks in calm, low, soothing tones, pouring his ugly philosophy into the ears of boys such as Danny. He is a snake in human form.
Avery Brooks, as the school's principal and Derek's former teacher, is a rock of integrity, a man who wants to help the brothers regain their moral equilibrium.
Beverly D'Angelo and Elliott Gould are featured as the brothers' mother and her would-be suitor.
Kaye refuses to allow a happy ending. Tragedy, built from hate and bigotry, strikes Derek's family, and the consequences of his earlier actions are brought home in the most brutal manner.
American History X is not a comfortable movie. It will make you squirm. It will shock and disgust you. But most of all it will sadden you. The movie is a fine treatise on hate, a movie that should not and cannot be ignored.
Bob Bloom is the film critic at the Journal and Courier in Lafayette, Ind. He can be reached by e-mail at<EMAIL_ADDRESS>or at<EMAIL_ADDRESS>cb
Carol Bloom of Bloom Ink Publishing Professionals 3312 Indian Rock Lane West Lafayette, IN 47906-1203<PHONE_NUMBER> fax<PHONE_NUMBER><EMAIL_ADDRESS>Committed to Lifelong Learning through Effective Communication
The review above was posted to the
rec.arts.movies.reviews newsgroup (de.rec.film.kritiken for German reviews).
The Internet Movie Database accepts no responsibility for the contents of the
review and has no editorial control. Unless stated otherwise, the copyright
belongs to the author.
Please direct comments/criticisms of the review to relevant newsgroups.
Broken URLs inthe reviews are the responsibility of the author.
The formatting of the review is likely to differ from the original due
to ASCII to HTML conversion.
Related links: index of all rec.arts.movies.reviews reviews


Your
neighborhood
soda shop
The business began as a small Italian grocery store in China town. It has been family owned and operated for more than hundred year. Although the focus of the store has changed to soda pop and beer from around the world, Galco’s still maintain Italian deli in the back of their retail store. In addition to soda shelves, people are amazed to find a wide selection of craft beers (local, national and international) along with such alcoholic spirits as hard ciders, hard-to-find sakes, exotic wines, French champagnes, honey meads and more. Galco’s also stocks a variety of artisanal waters for everyone’s drinking pleasure. Kids of all ages enjoy checking out our vintage candies and sweets next to a retro toy corner where you can pick up a memory or two.
Soda
It took a few years, but the idea finally caught on! People started journeying from far away places to get a look at the store with over 600 sodas. Visit Galco’s and find your soda! And also we offer DIY soda! A million possible soda combinations await you at Galco’s, with its revolutionary Soda Creation Station where anyone can make an unique soft drink to their liking.
Beer
With 10 new refrigerated cases devoted to artisanal beer in bottles, Galco’s offers more than 600 different brews, many beers that customers might not have known existed. Stocking beers from around the world, Galco’s offers 100 different Belgians, imports from England to Mexico in addition to an overwhelming amount of space devoted to American craft beers, including Eagle Rock Brewery, Fat Tire, Unita Lagunitas and Russian River. Newly arrived batches of seasonal ales often are delivered weekly.
Sandwiches
“Wow! This is a real blockbuster!”
Marciano reportedly uttered. Since that day, Galco’s renamed their sandwiches Blockbusters in honor of The Champ’s statement.
Galco’s moved to Highland Park in 1955. Today, in keeping with Galco’s motto of Freedom of Choice, the Galco’s deli offers a variety of sandwiches alongside the original Blockbuster. Also, in keeping with Galco’s commitment to support small, local businesses, deli ingredients come from family-owned stores in the area


--- title: Address description: Use an address lookup when you are asking users for a Singapore address. react-link: ?path=/docs/components-form-patterns--address toc: true --- {% capture address-pattern %}
Avoid changing the default order of address fields
Do ensure that the postal code field is on top as the address lookup can simplify the process of filling out the address field
Default to current date and month
Auto-filling helps users fill forms faster, but don't forget to leave these fields available for editing to give users control


EntityFixedYawAxis()
语法
EntityFixedYawAxis(#Entity, Enable [, VectorX, VectorY, VectorZ])概要
Change the fixed yaw axis of the entity. The default behaviour of a entity is to yaw around its own Y axis.
参数
#Entity 使用该实体。 Enable Enable or disable the use of a custom yaw axis. If set to #True, a new axis vector has to be specified. If set to #False, the entity will yaw around its own Y axis. VectorX (optional) X vector direction of the new yaw axis (value between -1.0 and 1.0). 'Enable' parameter has to be set to have any effect. VectorY (optional) Y vector direction of the new yaw axis (value between -1.0 and 1.0). 'Enable' parameter has to be set to have any effect. VectorZ (optional) Z vector direction of the new yaw axis (value between -1.0 and 1.0). 'Enable' parameter has to be set to have any effect.
返回值
无.
已支持操作系统
所有


--- layout: presentation title: "Lessons Learned - Tech Talk Tuesday" --- Lessons Learned Tech Talk Tuesday June 4th, 2019 Azure Cloud ARM Templates - Nesting/Inheriting Resource Groups MSDN Subscription Personal Subscription Free Resources Azure DevOps Projects Azure DevOps YAML Free Pipelines Free Repos PowerShell Set-ExecutionPolicy -ExecutionPolicy Bypass -Scope Process -Force Pipelining Object oriented Unit testing with Pester See my prior talk... VS Code Fast Lightweight Not as much hand holding See my prior talk... Load Balancer Configuration Layer 4 - Protocol aware Layer 7 - HTTP aware Certificate conversion Angular CLI Can be slow Bulky npm ci .NET Core Templates NuGet Glorified zip Enforced versioning Markdown Use a linter Fast content creation Blob Storage Temporary keys So cheap Static sites Serverless Durable functions Many triggers Logic apps Windows Configuration Management Chocolatey Boxstarter PowerShell DSC :-( CosmosDB Multi-modal Watch the scale Keeps getting better Scaling Patterns Lots of ways... Keep it small Low overhead/linear scale out It's Your Fault It's never the network It's never Azure It's always you... Podcasts - Azure Specific The Azure Podcast ←at least listen to the intro/news .NET Rocks RunAs Radio The Azure DevOps Podcast Podcasts - General Software/Tech Tech Meme Ride Home Software Engineering Radio Software Engineering Daily The 6 Figure Developer Data Skeptic The Hanselminutes Podcast Me, in the Wild slack.lansing.codes digestibledevops.com twitter.com/thiedebr
Tech Talk Tuesday June 4th, 2019
Set-ExecutionPolicy -ExecutionPolicy Bypass -Scope Process -Force
npm ci


Magnitude 5.9 earthquake jolts region of northwestern Iran
by The Associated Press, StaffTEHRAN, Iran -- Iran's state TV says a magnitude 5.9 earthquake has struck the northwest of the country. There are no immediate reports of casualties or damage.
The report says the quake hit at 2:20 a.m. Friday in Iran's East Azarbaijan province. It says the temblor occurred at a depth of two kilometres (1.2 miles).
The U.S. Geological Survey puts the quake's magnitude at 5.8 at a depth of 10 kilometres (6.2 miles).
A magnitude 5 earthquake can cause considerable damage.
Iran is located on major seismic faults and experiences one earthquake a day on average. In 2003, a magnitude 6.6 earthquake flattened the historic city of Bam, killing 26,000 people.


---
layout: null
section-type: about
title: About
---
## About
꿈 속에서 뱀이 온 몸을 휘감던 날, 작은 소년이 태어났습니다. 아주 평범한 소년이었습니다. 하지만, 그 소년에게는 큰 꿈이 있었습니다. 바로, 세상을 바꾸겠다는 것이었죠. "모든 사람이 원하는 삶을 살게 된다면 얼마나 좋을까?" 2017년, 그 꿈에 한 발자국 다가가기 위해서 블로그를 만들었습니다.
The day when a snake coiled around a woman in a dream, a little boy was born. He was just an ordinary boy. But, he had big dream. It is a hope to change his world. "How marvellous it would be if people could live as they want?" In 2017, he made a blog to be one step closer to his dream.
This blog is for newbie programer.
You can change your world if you want to and I am glad to support you.
Keep your eye on him by following!


Repl Classroom Manager
Student Data
(current)
Classrooms
(current)
Clone content
(current)
{{ g.year.name }}
(current)
Switch year
{% for year in g.years %}
{{ year.name }}
{% endfor %}
{% from "_formhelpers.html" import render_field %} {% block content %} {% endblock %}


Google Summer of Code 2017 is coming to an end. After three month of working on the BeeWare project, I would like to summarise my work and share my experiences.
“No Battle Plan Survives First Contact.”
This was one of the first things Russell said to me after we decided to fundamentally restructure my proposed GSoC timetable and goals. During the community bounding period we discovered that Toga was even harder to test as we expected. The tight coupling between the platform independent Toga-Core part and the platform dependent implementations for (Windows, macOS, iOS, Linux, Android, Django, ...) was giving us a hard time to write meaningful tests.
We expect Toga to become a decently sized project, therefore we want it to have a solid and well tested base. Given that, we decided that I would spend most of GSoC to restructure Toga to make it more testable. Besides that, I would also add implementation tests to check if a given backend is implemented in the right way. If I would finish before the end of the summer I would just start with my original project proposal.
The Big Restructure of Toga
With the new goals and a fresh branch I started the journey to restructure the Toga project to make it more testable.
After hacking around and testing different things on a separate branch. I identified that the intertwined platform dependencies are the main problem. To separate the Toga-Core module form its backend implementations we decided to use the factory pattern instead of the inheritance model that we had before. Now every backend has its own factory that produces the right widgets for the platform it is running on. This way we have a clear separation between Toga-Core and the implementation level. Platform dependencies are now enclosed in the implementation level.
After the new structure was clear I ported Toga-Core as well as the backends for cocoa, iOS and GTK. I did this in the Toga branch (The Big Restructure of Toga [WIP] #185). In practice this meant that I had to manually touch almost every widget of all backends to port them to the new factory pattern.
Challenges
Toga talks to native GUI frameworks, hence I had to get a good understanding about the principles and concepts behind each and every of these frameworks. At times I felt overwhelmed by the combined complexity of all the parts that make up Toga. The following is list:
- Every Toga backend wraps around a existing and unique framework. To wrap the framework you have to understand the framework.
- “I love Python, why do I have to understand Objective C”? To effectively work on the iOS and macOS backends I had to learn the basics of Objective C – if only to read the Apple docs.
- Toga has a lot of moving parts. There are backends, frameworks, libraries to talk to backends, libraries to perform the layout of the UI and more. I spend a good amount of time to understand all of these parts. The following is just a overview of newly acquired knowledge during GSoC:
- Rubicon-ObjC to talk to the iOS and macOS backends.
- Colosseum to understand and fix layout problems.
- AST module to perform the implementation tests.
- The use of Design Patterns
- How to structure large projects.
- Read and understand big and complex code chunks.
Other work I did
- PR: Translated part of the beeware.org webpage into german. (PR #173)
- Helped newcomers on Gitter and GitHub.
- Tested if Toga would profit from static typing (toga/static_typing).
- Created an implementation test suite based on the AST module.
- Added test for Toga-Core.
- Updated and extended documentation on Toga-Core as well as the macOS and iOS Backend.
- Created a toga-dummy backend.
- First draft of the Settings API and working backend implementation for macOS.
- Many small and big fixes on Toga-Core, cocoa, iOS, and GTK backends. All in the main PR beeware/toga The Big Restructure of Toga [WIP]
- PR: beeware/toga fix for getting the length of the filenames array
- PR: beeware/toga Fixed #189 cocoa.progressbar with rehint
- PR: beeware/briefcase-template Fix for spaces in app name. Issue #2
- PR: beeware/toga Toga Settings API [WIP]
Future Work to be Done
- All my work sits in the PR “The Big Restructure of Toga [WIP]”. After the missing backends, namely Windows and Android, are ported, everything can be merged into master. We have to wait for the missing backends, because the new is incompatible with the old versions and they can’t coexist.
- The Settings API from my original proposal is not finished because of the above mentioned reasons. I have a first working draft and I will continue working on it after GSoC in this PR.
Shoutout
I would like to thank Russell Keith-Magee for being an awesome Mentor and for all the time he invested in me during GSoC. I also would like to thank the BeeWare community for helping me when ever I had a problem. Thank you!
- Next entry
- 2017 Google Summer of Code - Batavia improvements
- Previous entry
- A new yak for the herd: BeeKeeper


Gateway
BOT
22-Apr-19 11:51 AM
[dscrdvrsc] <Thoskk> I wish this all wouldn't always take so much time to get into... I'm already spending a good part of my leisure time for all of this, and it doesn't seem to get less with each new development
[dscrdvrsc] <Thoskk> so much for "computers make it all easier" ... dafagg they do ...
[dscrdvrsc] <Oink> Well, if it aint broke, don't fix it....
[dscrdvrsc] <Thoskk> different thing
[dscrdvrsc] <Thoskk> it's more about what you have to do to get it halfways safe and secure
[dscrdvrsc] <Oink> The main reason I'm going to look at docker is to see if I can get that verusPay test site running smoother...
(edited)
[dscrdvrsc] <Thoskk> yes, Docker sounds great, just I'm so not motivated to setup another thing on top of all others again...
[dscrdvrsc] <Oink> But I agree, every new technology is a steep learning curve, eating away time
[dscrdvrsc] <Thoskk> absolutely
[dscrdvrsc] <Oink> The LAN pool runs fine on VBox, so i"ld leave that alone, if I were you. (Unless I 'transplant' it into Docker before you have yours up)
(edited)
[dscrdvrsc] <Thoskk> if people had to spend the same time with learning about new things in their cars that is necessary to get your IT safe and sound (as far as possible), you wouldn't see a tenth of the new cars on the streets that you currently can see.
[dscrdvrsc] <Oink> Hahahaha. So very true
[dscrdvrsc] <Thoskk> well, setting up my other machine is more tricky than I thought ... having driver issues for the GPU. At the moment it only works correctly when I'm logged in from remote
[dscrdvrsc] <Oink> That’s annoying.... but at least you still have access... I’ve experienced complete lockouts, only to be solved by taking out the offending hardware.... (LOOOOOOONG time ago)
[dscrdvrsc] <Thoskk> well, that times have passed for me when NT technology came up for windows, luckily. Had this a few times with Win95 and ME, though... install, restart ... nothing.
[dscrdvrsc] <Thoskk> but it was comparably easy to get it fixed.
(edited)
[dscrdvrsc] <Oink> I used to have an ancient PCI VGA card for those cases....
[dscrdvrsc] <Oink> VLB cards were a menace, without proper drivers...
[dscrdvrsc] <Thoskk> all hardware was
[dscrdvrsc] <Crupti> @Oink It´s pretty simple to learn Docker. The Dockerfile describes what should be done, if you look at the ccminer Dockerfile then it´s simple to understand. First the FROM command tells it to download a nvidia linux distro that has CUDA 10.1 preinstalled. The first RUN command updates the linux distro in the FROM and installs all the compilers etc - the next RUN line does all the downloading and building of the ccminer software on the linux distro specified in the FROM, then I just create a new on the linux distro in the FROM line so that you won´t have to run as root - and your basically done. Easy
(edited)
[dscrdvrsc] <Thoskk> I spent a week to get my Win95 laptop to run with the network of the hostel, back then...
[dscrdvrsc] <Oink> I used to connect CNC milking machines, controlled by DOS or WIN 311, to windows server 2003 and up....
[dscrdvrsc] <Thoskk> well, THAT sounds like FUN haha
[dscrdvrsc] <Thoskk> Telnet is your friend
[dscrdvrsc] <Oink> As it turned out, hardly anybody knows the tricks to get it connecting.... since modern win servers use SMB3
[dscrdvrsc] <Oink> Couple of old floppies, Dos networking....
[dscrdvrsc] <Oink> Disabling enforced use of smb3... voila, piece of cake
[dscrdvrsc] <Oink> Biggest problem was usually to get the network drivers running, without hogging all base memory... emm386 couldn’t be used because of the CNC controller that needed to run in real mode.
[dscrdvrsc] <Thoskk> when we set up the lab net at that time, we had to connect Win3.11, OS half ... ehm, OS/2, Linux and Unix machines in the same net ... I wasn't involved too much, but I've seen the network admin become grey haired within months
[dscrdvrsc] <Oink> Luckily only a handful of those customers every year
[dscrdvrsc] <Oink> It’s easy, no netbios, no netbeui, only tcp/ip...
[dscrdvrsc] <Oink> Get 1 WINS server on the network and it all works
[dscrdvrsc] <Thoskk> just the computer center would demand netbios
[dscrdvrsc] <Thoskk> IP conflicts over and over
[dscrdvrsc] <Oink> So IP management was new to the network admin.... whoehahaha
[dscrdvrsc] <Thoskk> it was just the beginning of the internet still... so, he wasn't a proper network admin, just a scientist with a more modern computer than others
[dscrdvrsc] <Oink> The least ignorant Computer hobby guy around...
[dscrdvrsc] <Thoskk> more or less, yes ^^
[dscrdvrsc] <Oink> I’ve seen those sites... always fun to straighten things out... Most amazing solutions to non-problems you’ll ever see.
[dscrdvrsc] <Oink> And the ‘IT-guy’ is always pissed of, because he’s no longer allowed to fool around anymore
[dscrdvrsc] <Thoskk> most of the labs were working on 286 PCs with 128bit graphics ... you know ... ^^
(edited)
[dscrdvrsc] <Oink> Yup...basically same stuff as the CNC-machines I ran into.
[dscrdvrsc] <Oink> Minus the graphics, of coarse
[dscrdvrsc] <Thoskk> compared to that, the 166 MHz machine running OS/2 was superfast ^^
[dscrdvrsc] <Oink> Hahahaha....
[dscrdvrsc] <Thoskk> it didn't have a Turbo button any more! Can you imagine!?
[dscrdvrsc] <Oink> Yes, I can....
[dscrdvrsc] <Oink> my first XT computer had a NEC V20 in it, running an amazing 9.56 MHZ....I had to actually use a slowdown TSR to be able to play games...
(edited)
[dscrdvrsc] <Thoskk>
[dscrdvrsc] <Thoskk> yes, I can remember that times ^^
[dscrdvrsc] <Thoskk> And I still have my first computer ... Commodore SX64 .. portable... way ahead of the time
[dscrdvrsc] <Thoskk> well, not the first, but the first portable
[dscrdvrsc] <Oink> Ah, a 'movable' computer...
[dscrdvrsc] <Thoskk> more like that, yes
[dscrdvrsc] <Thoskk> no batteries included
[dscrdvrsc] <Oink> In the navy they had those cases back then.


QGeoRoute Class
The QGeoRoute class represents a route between two points. More...
| Header: | #include <QGeoRoute> |
| qmake: | QT += location |
| Since: | Qt 5.6 |
Public Functions
| QGeoRoute() | |
| QGeoRoute(const QGeoRoute &other) | |
| ~QGeoRoute() | |
| QGeoRectangle | bounds() const |
| qreal | distance() const |
| QGeoRouteSegment | firstRouteSegment() const |
| QList<QGeoCoordinate> | path() const |
| QGeoRouteRequest | request() const |
| QString | routeId() const |
| void | setBounds(const QGeoRectangle &bounds) |
| void | setDistance(qreal distance) |
| void | setFirstRouteSegment(const QGeoRouteSegment &routeSegment) |
| void | setPath(const QList<QGeoCoordinate> &path) |
| void | setRequest(const QGeoRouteRequest &request) |
| void | setRouteId(const QString &id) |
| void | setTravelMode(QGeoRouteRequest::TravelMode mode) |
| void | setTravelTime(int secs) |
| QGeoRouteRequest::TravelMode | travelMode() const |
| int | travelTime() const |
| bool | operator!=(const QGeoRoute &other) const |
| QGeoRoute & | operator=(const QGeoRoute &other) |
| bool | operator==(const QGeoRoute &other) const |
Detailed Description
The QGeoRoute class represents a route between two points.
A QGeoRoute object contains high level information about a route, such as the length the route, the estimated travel time for the route, and enough information to render a basic image of the route on a map.
The QGeoRoute object also contains a list of QGeoRouteSegment objecs which describe subsections of the route in greater detail.
Routing information is normally requested using QGeoRoutingManager::calculateRoute(), which returns a QGeoRouteReply instance. If the operation is completed successfully the routing information can be accessed with QGeoRouteReply::routes()
See also QGeoRoutingManager.
Member Function Documentation
QGeoRoute::QGeoRoute()
Constructs a route object.
QGeoRoute::QGeoRoute(const QGeoRoute &other)
Constructs a route object from the contents of other.
QGeoRoute::~QGeoRoute()
Destroys this route object.
QGeoRectangle QGeoRoute::bounds() const
Returns a bounding box which encompasses the entire route.
See also setBounds().
qreal QGeoRoute::distance() const
Returns the distance covered by this route, in meters.
See also setDistance().
QGeoRouteSegment QGeoRoute::firstRouteSegment() const
Returns the first route segment in the route.
Will return an invalid route segment if there are no route segments associated with the route.
The remaining route segments can be accessed sequentially with QGeoRouteSegment::nextRouteSegment.
See also setFirstRouteSegment().
QList<QGeoCoordinate> QGeoRoute::path() const
Returns the geometric shape of the route.
The coordinates should be listed in the order in which they would be traversed by someone traveling along this segment of the route.
See also setPath().
QGeoRouteRequest QGeoRoute::request() const
Returns the route request which describes the criteria used in the calculation of this route.
See also setRequest().
QString QGeoRoute::routeId() const
Returns the identifier of this route.
Service providers which support the updating of routes commonly assign identifiers to routes. If this route did not come from such a service provider the function will return an empty string.
See also setRouteId().
void QGeoRoute::setBounds(const QGeoRectangle &bounds)
Sets the bounding box which encompasses the entire route to bounds.
See also bounds().
void QGeoRoute::setDistance(qreal distance)
Sets the distance covered by this route, in meters, to distance.
See also distance().
void QGeoRoute::setFirstRouteSegment(const QGeoRouteSegment &routeSegment)
Sets the first route segment in the route to routeSegment.
See also firstRouteSegment().
void QGeoRoute::setPath(const QList<QGeoCoordinate> &path)
Sets the geometric shape of the route to path.
The coordinates in path should be listed in the order in which they would be traversed by someone traveling along this segment of the route.
See also path().
void QGeoRoute::setRequest(const QGeoRouteRequest &request)
Sets the route request which describes the criteria used in the calculcation of this route to request.
See also request().
void QGeoRoute::setRouteId(const QString &id)
Sets the identifier of this route to id.
Service providers which support the updating of routes commonly assign identifiers to routes. If this route came from such a service provider changing the identifier will probably cause route updates to stop working.
See also routeId().
void QGeoRoute::setTravelMode(QGeoRouteRequest::TravelMode mode)
Sets the travel mode for this route to mode.
This should be one of the travel modes returned by request().travelModes().
See also travelMode().
void QGeoRoute::setTravelTime(int secs)
Sets the estimated amount of time it will take to traverse this route, in seconds, to secs.
See also travelTime().
QGeoRouteRequest::TravelMode QGeoRoute::travelMode() const
Returns the travel mode for the this route.
This should be one of the travel modes returned by request().travelModes().
See also setTravelMode().
int QGeoRoute::travelTime() const
Returns the estimated amount of time it will take to traverse this route, in seconds.
See also setTravelTime().
bool QGeoRoute::operator!=(const QGeoRoute &other) const
Returns whether this route and other are not equal.
QGeoRoute &QGeoRoute::operator=(const QGeoRoute &other)
Assigns the contents of other to this route and returns a reference to this route.
bool QGeoRoute::operator==(const QGeoRoute &other) const
Returns whether this route and other are equal.


In the following, you will be presented with 8 short background stories. Please read them very carefully. We ask you to rate 2 statements for each background story. Please indicate, using an adjustable slider bar, how likely you think a statement is true based on the background story.
Background story: Joe went shopping yesterday, while his wife Sue was at home with the kids. He bought flowers for his wife on the way home.
Statement 1: Joe went shopping without his wife Sue.
Statement 2: Sue was very happy about the flowers.
Statement 3: Joe and Sue are divorced.
Statement 4: Joe and Sue have no children.


Lab 4: Lists
Question 1: List indexing
Predict what Python will display when you type the following into the interpreter. Then try it to check your answers.
>>> x = [1, 2, 3]
>>> x[0]
______1
>>> x[2]
______3
>>> x[3]
______IndexError
>>> x[-1]
______3
>>> x[-3]
______1
Question 2: List slicing
Predict what Python will display when you type the following into the interpreter. Then try it to check your answers.
>>> x = [1, 2, 3, 4]
>>> x[1:3]
______[2, 3]
>>> x[:2]
______[1, 2]
>>> x[1:]
______[2, 3, 4]
>>> x[-2:3]
______[3]
>>> x[-2:4]
______[3, 4]
>>> x[0:4:2]
______[1, 3]
>>> x[::-1]
______[4, 3, 2, 1]
Python can retrieve part of a list by slicing.
We can write [start:end:step]
to slice a list.
start
: the index for the beginning of the sliceend
: the index for the end of the slicestep
: how big your step size is
Using negative indices for start
and end
behaves the same way
as indexing into negative indices. Negative step
means to move
backwards.
Slicing a list creates a new list, without modifying the original list.
Question 3: List operations
Predict what Python will display when you type the following into the interpreter. Then try it to check your answers.
>>> y = [1]
>>> len(y)
______1
>>> 1 in y
______True
>>> y + [2, 3]
______[1, 2, 3]
>>> [0] + y
______[0, 1]
>>> y * 3
______[1, 1, 1]
>>> z = [[1, 2], [3, 4, 5]]
>>> len(z)
______2
Question 4: Fill in the blanks
Fill in the blanks for the following lines so that each expression
evaluates to the expected output:
>>> x = [1, 3, [5, 7], 9]
>>> _______________
7
>>> x = [[7]]
>>> _______________
7
>>> x = [1, [2, [3, [4, [5, [6, [7]]]]]]]
>>> _______________
7
x[2][1]
x[0][0]
x[1][1][1][1][1][1][0]
Question 5: Reverse (iteratively)
Write a function reverse_iter
that takes a list and returns a new
list that is the reverse of the original. Use iteration! You may also
use slicing notation. Do not use lst[::-1]
!
def reverse_iter(lst):
"""Returns the reverse of the given list.
>>> reverse_iter([1, 2, 3, 4])
[4, 3, 2, 1]
"""
"*** YOUR CODE HERE ***"
new, i = [], 0
while i < len(lst):
new = [lst[i]] + new
i += 1
return new
Question 6: Reverse (recursively)
Write a function reverse_recursive
that takes a list and returns a
new list that is the reverse of the original. Use recursion! You may
also use slicing notation. Do not use lst[::-1]
!
def reverse_recursive(lst):
"""Returns the reverse of the given list.
>>> reverse_recursive([1, 2, 3, 4])
[4, 3, 2, 1]
"""
"*** YOUR CODE HERE ***"
if not lst:
return []
return reverse_recursive(lst[1:]) + [lst[0]]
Sequences and For Loops
Sequences are ordered collections of values that support element-selection and have length. The most common sequence we work with are lists, but many other Python types are sequences as well, including strings.
Sequences are of key importance in Python programming since they are considered iterable objects
and can be used freely in for loops.
Here are a few powerful higher-order functions that process sequences:
map(fn, seq)
: applies a functionfn
onto every element in the given sequenceseq
.filter(cond, seq)
: keeps elements in the sequenceseq
only if those elements satisfy the condition functioncond
(that is, for an elementx
, keep it only ifcond(x)
is True).reduce(combiner, seq)
: combines all elements in the sequenceseq
with thecombiner
function (which must take two arguments), starting from the first twoseq[0], seq[1]
initial values of seq.
Notes: When working with higher-order functions we often create in-line lambda expressions,
allowing us to create simple functions without defining them with a name. Such lambda expressions consist of a list of arguments and a simple expression, e.g., the addition function with two arguments is written lambda x, y: x + y
.
The higher-order map
and filter
functions are built-in to python3 but reduce
is in the functools
package.
You must import reduce
from functools
like this:
>>> from functools import reduce
>>> reduce(lambda x, y: x + y, [1, 2, 3])
6
Note: map
and filter
do not return lists. Instead, map
returns a map
object and filter
returns a filter
object. We can convert these objects to
lists by using the list
constructor:
>>> map(lambda x: x * x, [1, 2, 3, 4])
<map object at ...>
>>> list(map(lambda x: x * x, [1, 2, 3, 4]))
[1, 4, 9, 16]
Question 7: Map, Filter, Reduce
As an exercise, implement three functions map
, filter
, and reduce
to behave like their built-in counterparts. For map
and filter
, you
can return the results as Python lists.
def map(fn, seq):
"""Applies fn onto each element in seq and returns a list.
>>> map(lambda x: x*x, [1, 2, 3])
[1, 4, 9]
"""
"*** YOUR CODE HERE ***"
result = []
for elem in seq:
result += [fn(elem)]
return result
def filter(pred, seq):
"""Keeps elements in seq only if they satisfy pred.
>>> filter(lambda x: x % 2 == 0, [1, 2, 3, 4])
[2, 4]
"""
"*** YOUR CODE HERE ***"
result = []
for elem in seq:
if pred(elem):
result += [elem]
return result
def reduce(combiner, seq):
"""Combines elements in seq using combiner.
>>> reduce(lambda x, y: x + y, [1, 2, 3, 4])
10
>>> reduce(lambda x, y: x * y, [1, 2, 3, 4])
24
>>> reduce(lambda x, y: x * y, [4])
4
"""
"*** YOUR CODE HERE ***"
total = seq[0]
for elem in seq[1:]:
total = combiner(total, elem)
return total
List Comprehension
A list comprehension
is Python syntax for quickly creating lists. List comprehensions are a very important part of Python syntax, which combines the following three higher level operations in a single statment.
- For loop: identifying a sequence to iterate over
- Map expression: what to do to each element in sequence
- Filter expression: which elements to keep (optional)
You should notice that in every list comprehension the map expression comes first, then the for loop expression, and ends with an optional filter expression. For example:
>>> seq = [1, 2, 3, 4]
>>> [x * x for x in seq if x % 2 == 0]
[4, 16]
Question 8: What would Python print?
What would Python print? Try to figure it out before you type it into the interpreter!
>>> [x*x for x in range(5)]
______[0, 1, 4, 9, 16]
>>> [n for n in range(10) if n % 2 == 0]
______[0, 2, 4, 6, 8]
>>> ones = [1 for i in ["hi", "bye", "you"]]
>>> ones + [str(i) for i in [6, 3, 8, 4]]
______[1, 1, 1, '6', '3', '8', '4']
>>> [i+5 for i in [n for n in range(1,4)]]
______[6, 7, 8]
Nested Lists and List Type Checking
A nested list is a list that appears as an element in another list. In this list, the element with index 3 is a nested list:
Bracket operators evaluate from left to right.
You can check if an object is a list (or other type) by using the built-in type function. For example,
>>> nested = ["hello", 2.0, 5, [10, 20]]
>>> print(nested[3])
[10, 20]
>>> elem = nested[3]
>>> elem[0]
10
>>> nested[3][1]
20
Using recursion and the type function, write a function which flattens a given list.
>>> type(3) == list
False
>>> type([1, 2, 3]) == list
True
>>> type(nested) == list
True
>>> type(nested[2]) == list
False
>>> type(nested[3]) == list
True
def flatten(lst):
"""Returns a flattened version of lst.
>>> flatten([1, 2, 3])
[1, 2, 3]
>>> x = [1, [2, 3], 4]
>>> flatten(x)
[1, 2, 3, 4]
>>> x = [[1, [1, 1]], 1, [1, 1]]
>>> flatten(x)
[1, 1, 1, 1, 1, 1]
"""


{% extends "base.html" %} {% block title %}
Medieval catalogues > CISTERCIANS
{% endif %}
All data was derived from the List of Identifications by Professor Richard Sharpe.
{% if not printing %}
A key to codes used in the List is available (opens in new tab).{% endif %}


Someone who wanted to argue that the United States was becoming an increasingly dangerous place would be more persuasive if they presented Figure 3.6.5, than Figure 3.6.6. Figure 3.6.6 shows that there is a noticeable drop in robberies in more recent years after the slight uptick for a couple of years.
in-context


Designed for reseachers
Outline a benefit here. change the icon above to FontAwesome icons available.
{% load static %}
A mobile-friendly tool designed to help researchers understand how language is used by the media
Explain project in detail.
Outline a benefit here. change the icon above to FontAwesome icons available.
Outline a benefit here. change the icon above to FontAwesome icons available.
Outline a benefit here. change the icon above to FontAwesome icons available.
Outline a benefit here. change the icon above to FontAwesome icons available.
Outline a benefit here. change the icon above to FontAwesome icons available.
Outline a benefit here. change the icon above to FontAwesome icons available.