This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Copyright 2017 Google Inc. | |
Licensed under the Apache License, Version 2.0 (the "License"); | |
you may not use this file except in compliance with the License. | |
You may obtain a copy of the License at | |
https://www.apache.org/licenses/LICENSE-2.0 | |
Unless required by applicable law or agreed to in writing, software |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
# Copyright 2017 Google LLC. | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at | |
# | |
# https://www.apache.org/licenses/LICENSE-2.0 | |
# |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <sstream> | |
void IterativeNestedLoop(int depth, int max, std::function<void(int* slots, int)> action) | |
{ | |
// Initialize the slots to hold the current iteration value for each depth | |
int* slots = (int*)alloca(sizeof(int) * depth); | |
for (int i = 0; i < depth; i++) | |
{ | |
slots[i] = 0; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Copyright 2017 Google LLC. | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* https://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var additionalFakeForecasts = { | |
'2357536' : { | |
key: '2357536', | |
label: 'Austin, TX', | |
created: '2016-07-22T01:00:00Z', | |
channel: { | |
astronomy: { | |
sunrise: "5:43 am", | |
sunset: "8:21 pm" | |
}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function fetchCall() { | |
const Http = new XMLHttpRequest(); | |
const host = window.location.href.substring(0, window.location.href.indexOf(window.location.pathname)); | |
const url = host + "/?file=1mb"; | |
Http.open("GET", url); | |
Http.send(); | |
Http.onreadystatechange = (e) => { | |
if (Http.readyState == XMLHttpRequest.DONE) { | |
document.getElementById("test_result").value = document.getElementById("test_result").value + | |
"\nReceived data, chunks remaining: " + _chunks; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Copyright 2020 Google LLC. | |
* SPDX-License-Identifier: MIT | |
*/ | |
using Microsoft.WindowsAPICodePack.Shell.PropertySystem; | |
using System; | |
using System.IO; | |
using System.Reflection; | |
using System.Runtime.CompilerServices; | |
using System.Runtime.InteropServices; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Copyright 2020 Google LLC. | |
* SPDX-License-Identifier: MIT | |
*/ | |
using Microsoft.Toolkit.Uwp.Notifications; | |
using System; | |
using System.Windows.Forms; | |
using Windows.Data.Xml.Dom; | |
using Windows.UI.Notifications; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copyright 2021 Google LLC. | |
# SPDX-License-Identifier: Apache-2.0 | |
search_input = driver.find_element_by_xpath("//input[@id='searchInput']") | |
search_input.clear() | |
search_input.send_keys('George Washington') | |
submit_button = driver.find_element_by_xpath("//button[@type='submit']") | |
submit_button.click() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copyright 2021 Google LLC. | |
# SPDX-License-Identifier: Apache-2.0 | |
import os | |
import pathlib | |
import re | |
months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'] | |
pattern_td = r'(.+)([A-Za-z]{3})_(\d\d)-([A-Za-z]{3})_(\d\d)\_(\d\d\d\d).pdf' | |
pattern_loc = r'(.+)([A-Za-z]{3})_(\d\d)(_|-)(\d\d\d\d).pdf' |
OlderNewer