Snippets Collections
<?php

/**

 * The template for displaying all single posts

 *

 * @link https://developer.wordpress.org/themes/basics/template-hierarchy/#single-post

 *

 * @package WordPress

 * @subpackage Twenty_Nineteen

 * @since Twenty Nineteen 1.0

 */

​

get_header();

?>

    <div id="primary" class="content-area">

        <main id="main" class="site-main">

            <?php

​

            // Start the Loop.

            while ( have_posts() ) :

                the_post();

​

                get_template_part( 'template-parts/content/content', 'single' );

​

                if ( is_singular( 'attachment' ) ) {

                    // Parent post navigation.

                    the_post_navigation(

                        array(

                            /* translators: %s: Parent post link. */

                            'prev_text' => sprintf( __( '<span class="meta-nav">Published in</span><span class="post-title">%s</span>', 'twentynineteen' ), '%title' ),

                        )

                    );

                } elseif ( is_singular( 'post' ) ) {

                    // Previous/next post navigation.

                    the_post_navigation(

                        array(

                            'next_text' => '<span class="meta-nav" aria-hidden="true">' . __( 'Next Post', 'twentynineteen' ) . '</span> ' .

                                '<span class="screen-reader-text">' . __( 'Next post:', 'twentynineteen' ) . '</span> <br/>' .

                                '<span class="post-title">%title</span>',

                            'prev_text' => '<span class="meta-nav" aria-hidden="true">' . __( 'Previous Post', 'twentynineteen' ) . '</span> ' .

                                '<span class="screen-reader-text">' . __( 'Previous post:', 'twentynineteen' ) . '</span> <br/>' .

                                '<span class="post-title">%title</span>',

                        )

                    );

                }

​
<?php

/**

 * The template for displaying all single posts

 *

 * @link https://developer.wordpress.org/themes/basics/template-hierarchy/#single-post

 *

 * @package WordPress

 * @subpackage Twenty_Nineteen

 * @since Twenty Nineteen 1.0

 */

​

get_header();

?>

    <div id="primary" class="content-area">

        <main id="main" class="site-main">

            <?php

​

            // Start the Loop.

            while ( have_posts() ) :

                the_post();

​

                get_template_part( 'template-parts/content/content', 'single' );

​

                if ( is_singular( 'attachment' ) ) {

                    // Parent post navigation.

                    the_post_navigation(

                        array(

                            /* translators: %s: Parent post link. */

                            'prev_text' => sprintf( __( '<span class="meta-nav">Published in</span><span class="post-title">%s</span>', 'twentynineteen' ), '%title' ),

                        )

                    );

                } elseif ( is_singular( 'post' ) ) {

                    // Previous/next post navigation.

                    the_post_navigation(

                        array(

                            'next_text' => '<span class="meta-nav" aria-hidden="true">' . __( 'Next Post', 'twentynineteen' ) . '</span> ' .

                                '<span class="screen-reader-text">' . __( 'Next post:', 'twentynineteen' ) . '</span> <br/>' .

                                '<span class="post-title">%title</span>',

                            'prev_text' => '<span class="meta-nav" aria-hidden="true">' . __( 'Previous Post', 'twentynineteen' ) . '</span> ' .

                                '<span class="screen-reader-text">' . __( 'Previous post:', 'twentynineteen' ) . '</span> <br/>' .

                                '<span class="post-title">%title</span>',

                        )

                    );

                }

​
/*
In this challenge you will test your knowledge of arrays and array methods.


THE PROBLEM:
SPAM is major problem on the internet. Email applications like gMail do a lot of
work to identify spam and remove them from user's inbox.

YOUR CHALLENGE:
Complete the code below to correctly process a set of messages. The ones identified
as spam should be placed in a spam folder, otherwise they should be placed in the
inbox folder. You are provided with a spam detector function "isSpam" that will
return true if a message is spammy, and false otherwise.

Good luck!
*/

// This is your spam detection function.
// It will return true is a message is spam, and false otherwise
// DON'T UPDATE THE NEXT LINE
const isSpam = (message) =>  /money/.test(message.content)


//  Accepts an array of messages and returns an object with two properties
//  spam, and inbox.
//  spam and inbox are array of spam and not spam messages respectively and are
//  sorted
function processMessages (messages) {

  // Hint: to sort the messages by time, you will use the sortFn below as your
  // compare fuunction.
  // the function accepts two message arguments (a and b) to be compared,
  // and you will be comparing the time property i.e a.time and b.time

  const sortFn = (a, b) => 0 // your code here (~ 1 line)

  // use the isSpam function provided above to determine if a message is a spam
  const inbox =  [] // code your here.
  const spam = [] // code your here.

 // DON'T UPDATE THE LINE BELOW.
 return {
    inbox,
    spam
  }
}
// THIS IS HERE FOR YOUR TEST ONLY
const messages = [
  {content: 'click here to make a lot of money', time: 10} ,
  {content: 'hello are are you', time: 4} ,
  {content: 'I just won some money, send your account number', time: 2},
  {content: 'do you want to have launch', time: 11},
  {content: 'we received your application', time: 3},
 ]
 const {spam, inbox } = processMessages(messages)
 // should print
 // [ "I just won some money, send your account number",
 //   "click here to make a lot of money"]
 console.log(spam.map(s => s.content))

 // should print
 // ["we received your application", "hello are are you",
 //  "do you want to have launch"]
 console.log(inbox.map(s => s.content))
/*
In this challenge you will test your knowledge of asynchronous functions.

THE PROBLEMit:
ATMs are very useful machines that give people access to their money when they
need them without having to go inside a bank. Bank customers want a fast and
reliable ATM experience.

Let's consider at a high-level the operations that an ATM machine might perform
for a simple cash withdrawal transaction.

1. Validate the customer's PIN
2. Validate that the customer has sufficient balance, if the pin is valid.
3. Update the customer's balance, if they have enough money to withdraw
4. Send notification e.g SMS to the user
5. Dispense the cash

For most customers step 5 is probably what they care most about, so it will make
sense to not to block on the notification operation which might take some time
and instead dispense the money before the notification is sent.

Asynchronous code can be very tricky to write and to understand. Synchronous code
is straightforward to follow and understand because the operations are performed
one after the other i.e sequentially.


YOUR CHALLENGE:
The withdraw function below depends on several asynchronous functions that are
already provided for you. Your task is to update the withdraw function to ensure
that the withdrawal logic executes correctly.
Since all the functions are asynchronous, very bad things can happen if the order
of execution is done correctly, e.g a person might be able to withdraw money even
if their pin is wrong, or when the don't have enough balance.

The bank is counting on your expertise to ensure that this doesn't happen!!!

Good luck!
*/


let cashInMachine = 1000000 // Don't update this line

async function withdraw (acctNum, amount, pin)  {
  try {

    // Your task is to update the function calls below so that
    // they execute in the right order.

    // HINT: These functions are all asynchronous so by default don't wont block.
    // To wait for a function to be done, add await in front of it.

    validatePin(acctNum, pin)

    validateBalance(acctNum, amount)

    updateBalance(acctNum, amount)

    notify(acctNum, amount)

    dispenseCash(amount);

    return `Dispensed ${amount}. Machine balance: ${cashInMachine}` // Don't update this line.
  } catch (er) {
    return er;
  }

}

// STUDY THE CODE BELOW, BUT DON'T MODIFY THEM.

const fakeDB = {
  12345: {
      pin: 1111,
      balance: 2000
      },
  45678: {
      pin: 2222,
      balance: 5000
      },
  678910: {
      pin: 3333,
      balance: 5000
      },
}
// returns an acccount object if present in DB, otherwise throws an error
async function getAccount(acctNum) {
  if(acctNum in fakeDB) {
    return fakeDB[acctNum]
  } else {
  throw 'account not found'
  }
}
// update account balance
async function updateBalance(acctNum, amount) {
  return new Promise ((resolve) => {
     setTimeout(async function() {
         const account = await getAccount(acctNum);
         account.balance -= amount;
         resolve('done');
     }, 150);
   });
 }

// throw an error if pin is incorrect
async function validatePin (acctNum, pin) {
    if ((await getAccount(acctNum)).pin !== pin ) {
       throw 'invalid pin';
    }
}
// throw an error if account balance is insufficient
async function validateBalance (acctNum, amount) {
    if ( (await getAccount(acctNum)).balance < amount ) {
       throw 'insufficient balance';
    }
}
// notify user of withdrawal and their current account balance
async function notify(acctNum, amount) {
  return new Promise ((resolve) => {
    setTimeout(async function() {
     const acct = await getAccount(acctNum);
     console.log(`You withdrew ${amount}. Your current balance is ${acct.balance}`)
     resolve('notified')
    }, 100);
  })
}
// disburse cash from machine
async function dispenseCash(amount) {
  return new Promise ((resolve) => {
    setTimeout(async function() {
       cashInMachine -= amount;
       resolve('dispensed')
    }, 50);

  });
}

// THIS IS HERE FOR YOUR TESTING ONLY
// *** PLEASE COMMENT OUT THE LINES BELOW BEFORE YOU SUBMIT ***
// Shoud only print:
// "Dispensed 500. Machine balance: 999500"
// "You withdrew 500. Your current balance is 1500"
console.log(await withdraw(12345, 500, 1111))  // comment out before submission

// Should  only print:
// "invalid pin"
// console.log(await withdraw(45678, 1000, 2221)) // comment out before submission
<div class="container">

  <img src="https://images.unsplash.com/photo-1882807628-e876f502d67a?dpr=1&auto=format&fit=crop&w=1500&h=1000&q=80&cs=tinysrgb&crop=&bg=" alt="" />

  <p class="title">card title</p>
4
  <div class="overlay"></div>
5
  <div class="button"><a href="#"> BUTTON </a></div>
6
</div>
/*
You are developing an ecommerce application which allows users to add items to a virtual shopping cart. Once the user is done shopping, we will need to know the total amount of money to charge the user based on what was purchased.
*/

// The cart array stores all of the items selected in the shopping cart

let cart = [];

// The quantity array stores the quantity of the items in the cart.
// The cart and quantity arrays are connected based on the index i.e
// given cart = ["bread", "apple"] and quantity = [2, 1]
// we can tell that we have two pieces of bread and 1 apple.
// The item at index 0 in cart i.e cart[0] is "bread", so we get the quantity
// at the same index in the quantity array i.e quantity[0]

let quantity = [];

// The prices multidimensional array stores the prices of the items in the
// store. There are 6 items that can be purchased from the store:
// "bread", "apple", "noodles", "beef", "milk" and "coke".
// The price for "bread" is 20, the price for "apple" is 50 and so on.

const prices = [
  ["bread", 20],
  ["apple", 50],
  ["noodles", 100],
  ["beef", 40],
  ["milk", 32],
  ["coke", 25],
];

// Given an item, Complete the code to add the item to the cart and quantity
// arrays.
// Don't touch this section, we will cover functions later.
function addItemToCart(item) {
  // item is a variable that represents the item that is being added to the
  // cart. Valid items are items present in the prices array i.e "bread",
  // "apple", "noodles", "beef", "milk" and "coke".
  // An invalid item e.g "rice"  should throw an error ‘item not recognized’
  
  let isValidItem = false;
  for (price of prices) {
    if(price === item){
      isValidItem= true;
    }
  }
  // TODO(2): Throw error "item not recognized" if isValidItem !== true i.e false
    if(isValidItem !== true){
      throw 'item not recognized'
    }
  let foundItem = false;
  // TODO(3): Write code to check if item is in the cart array, and if so set
  // foundItem = true, and increase the quantity of the item by 1
  // Hint: Use the index where the item was found in the cart to increase the
  // quanity in the quantity array
   for(i=0; i< cart.length; i++){
     if(item === cart[i]){
       foundItem = true;
       quantity++
   }
  // TODO(4): Write code to add item to cart and set quantity to 1, if item is
  // was not found in the cart i.e foundItem is not true.
  // Hint: To set the quantity for the recently added item to 1,
  // do quantity.push(1)
  if(foundItem !== true){
   quantity.push(1)
 }
}
 
// Write the code to calculate the total cost of all items in the cart based on
// the items in the cart and the quantity of the items purchased. The total
// cost should be stored in the total variable
// Don't touch the next line, we will cover functions later.
function getTotal() {
  let total = 0;

  for (let i = 0; i < cart.length; i++) {
    let item = cart[i];
    let qty = quantity[i];
    let subtotal = 0;
    // TODO(7) : Loop through the prices array to get the price of item, then
    // compute and set subtotal by multiplying the price and qty.
    // Hint: Each array in prices has the item at index 0, and the price at
    // index 1
    for(price of prices){
      if(item === price){
        subtotal += price[1]*qty
        break
      }
    }
    // TODO(8): Add subtotal to total (this should after the loop above)
    total += subtotal
  }
  return total; // Do not edit or remove this line.
}

// THIS IS FOR YOUR TESTING ONLY.
try {
  addItemToCart("apple");
  addItemToCart("apple");
  addItemToCart("beef");
  addItemToCart("milk");
  console.log(addItemToCart("rice")); // This should print 'item not recognized'
} catch (e) {
  console.log(e);
}
console.log(cart.length); // This should print 3
console.log(quantity[0]); // This should print 2
console.log(getTotal()); // This should print 172
​// arrow function definition
const speak = (name) => {  // this sign(=>) represents the function...
   return "Shout " + name;
   }
console.log(speak('chisom'))
(\()?(\+62|62|0)(\d{2,3})?\)?[ .-]?\d{2,4}[ .-]?\d{2,4}[ .-]?\d{2,4}
/************************************************************

    Following is the TreeNode class structure

    template <typename T>
    class TreeNode {
       public:
        T data;
        TreeNode<T> *left;
        TreeNode<T> *right;

        TreeNode(T data) {
            this->data = data;
            left = NULL;
            right = NULL;
        }
    };

************************************************************/

string serializeTree(TreeNode<int> *root)
{
 //    Write your code here for serializing the tree
queue<TreeNode<int>*> q;
    q.push(root);
    string output="";
    while(!q.empty()){
         TreeNode<int> *temp=q.front();
        q.pop();
     if(temp!=NULL) {
        char c=48+temp->data;
        output=output+c+" ";
        q.push(temp->left);
        q.push(temp->right);
       }
      else output=output+"-1 ";
    }
    return output;
}
TreeNode<int>* deserializeTree(string &serialized)
{
 //    Write your code here for deserializing the tre
    if(serialized[0]=='-') return NULL;
    queue<TreeNode<int>*>  q;
    int curr=serialized[0]-48;
    TreeNode<int> *root=new TreeNode<int>(curr);
    q.push(root);
    int i=2;
    while(!q.empty()){
        TreeNode<int> *top=q.front();
        q.pop();
        int val1=serialized[i]-48;
        if(val1>=0){
            TreeNode<int> *Node1=new TreeNode<int>(val1);
            q.push(Node1);
            top->left=Node1;
            i+=2;
        }
        else  i+=3;
        int val2=serialized[i]-48;
        if(val2>=0){
            TreeNode<int> *Node2=new TreeNode<int>(val2);
            q.push(Node2);
            top->right=Node2;
            i+=2;
        }
        else   i+=3;
    }
    return root;
}



/**

 * @snippet       Display supplier @ WooCommerce Single Product Page

 * @how-to        Get CustomizeWoo.com FREE

 * @author        Rodolfo Melogli

 * @compatible    WC 4.
6
 * @donate $     https://businessbloomer.com/bloomer-armada/

 */

  
9
// -----------------------------------------

// 1. Add supplier field input @ product edit page

  

add_action( 'woocommerce_product_options_pricing', 'bbloomer_add_supplier_to_products' );      

  

function bbloomer_add_supplier_to_products() {          

    woocommerce_wp_text_input( array( 

        'id' => 'supplier', 

        'class' => 'short wc_input_price', 

        'label' => __( 'מחיר ספק ללא מע"מ', 'woocommerce' ) . ' (' . get_woocommerce_currency_symbol() . ')',

        'data_type' => 'price', 

    ));      

}

  

// -----------------------------------------

// 2. Save supplier field via custom field

  

add_action( 'save_post_product', 'bbloomer_save_supplier' );

  

function bbloomer_save_supplier( $product_id ) {

    global $pagenow, $typenow;

    if ( 'post.php' !== $pagenow || 'product' !== $typenow ) return;

    if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return;

    if ( isset( $_POST['supplier'] ) ) {

        update_post_meta( $product_id, 'supplier', $_POST['supplier'] );

    }

}
console.clear();

//people droppig a form (action creator)

const creatPolicy =(name,amount)=>{

  return{//action(form in our analogy)

    type:'CREATE_Policy',

    payload:{

      name,amount

    }  

  }  

}

​

const deletePolicy =(name,amount)=>{

  return{//action(form in our analogy)

    type:'DELETE_Policy',

    payload:{

      name,amount

    }  

  }  

}

​

const creatClaim =(name,amountOfMoneytoCollect)=>{

  return{//action(form in our analogy)

    type:'CREATE_CLAIM',

    payload:{

      name,amountOfMoneytoCollect

    }  

  }  

}

//reducer department

 const ClaimHistory =(oldListOfClaim=[],form)=>{

   if(action.type===CREATE_CLAIM)

    { //we care about this action

       return [...oldListOfClaim ,action.payload]

    }
console.clear();

//people droppig a form (action creator)

const creatPolicy =(name,amount)=>{

  return{//action(form in our analogy)

    type:'CREATE_Policy',

    payload:{

      name,amount

    }  

  }  

}

​

const deletePolicy =(name,amount)=>{

  return{//action(form in our analogy)

    type:'DELETE_Policy',

    payload:{

      name,amount

    }  

  }  

}

​

const creatClaim =(name,amountOfMoneytoCollect)=>{

  return{//action(form in our analogy)

    type:'CREATE_CLAIM',

    payload:{

      name,amountOfMoneytoCollect

    }  

  }  

}

//reducer department

 const ClaimHistory =(oldListOfClaim=[],form)=>{

   if(action.type===CREATE_CLAIM)

    { //we care about this action

       return [...oldListOfClaim ,action.payload]

    }
console.clear();

//people droppig a form (action creator)

const creatPolicy =(name,amount)=>{

  return{//action(form in our analogy)

    type:'CREATE_Policy',

    payload:{

      name,amount

    }  

  }  

}

​

const deletePolicy =(name,amount)=>{

  return{//action(form in our analogy)

    type:'DELETE_Policy',

    payload:{

      name,amount

    }  

  }  

}

​

const creatClaim =(name,amountOfMoneytoCollect)=>{

  return{//action(form in our analogy)

    type:'CREATE_CLAIM',

    payload:{

      name,amountOfMoneytoCollect

    }  

  }  

}

//reducer department

 const ClaimHistory =(oldListOfClaim=[],form)=>{

   if(action.type===CREATE_CLAIM)

    { //we care about this action

       return [...oldListOfClaim ,action.payload]

    }
console.clear();

//people droppig a forn (action creator)

const creatPolicy =(name,amount)=>{

  return{//action(form in our analogy)

    type:'CREATE_Policy',

    payload:{

      name,amount

    }  

  }  

}

​

const deletePolicy =(name,amount)=>{

  return{//action(form in our analogy)

    type:'DELETE_Policy',

    payload:{

      name,amount

    }  

  }  

}

​

const creatClaim =(name,amountOfMoneytoCollect)=>{

  return{//action(form in our analogy)

    type:'CREATE_CLAIM',

    payload:{

      name,amount

    }  

  }  

}
console.clear();

//people droppig a forn (action creator)

const creatPolicy =(name,amount)=>{

  return{//action(form in our analogy)

    type:'CREATE_Policy',

    payload:{

      name,amount

    }  

  }  

}

​

const deletePolicy =(name,amount)=>{

  return{//action(form in our analogy)

    type:'DELETE_Policy',

    payload:{

      name,amount

    }  

  }  

}

​

const creatClaim =(name,amountOfMoneytoCollect)=>{

  return{//action(form in our analogy)

    type:'CREATE_CLAIM',

    payload:{

      name,amount

    }  

  }  

}
/**

 Display "Sold Out" on Loop Pages - WooCommerce

 */

 

add_action( 'woocommerce_before_shop_loop_item_title', 'bbloomer_display_sold_out_loop_woocommerce' );

 

function bbloomer_display_sold_out_loop_woocommerce() {

    global $product;

 

    if ( !$product->is_in_stock() ) {

        echo '<span class="soldout">' . __( 'אזל מהמלאי', 'woocommerce' ) . '</span>';

    }

} 

​

/**

* Change "Out of stock" to "Sold Out"

* @param string $text

* @param WC_Product $product

* @return string

*/

function puri_woocommerce_get_availability_text( $text, $product ) {

    if (!$product->is_in_stock()) {

        $text = 'המוצר אזל מהמלאי, לכניסה לרשימת המתנה, אנא צרו קשר!';

    } else {

    // You can add more conditions here. e.g if product is available.

    // $text = 'Available right now';

    }

    return $text;

}

​

add_filter( 'woocommerce_get_availability_text', 'puri_woocommerce_get_availability_text', 999, 2);

​

/**

*  Out of stock message for product variations.

* @param string $text default message.

* @return string

*/

function puri_out_of_stock_message( $text ){

 $text = 'המוצר אזל מהמלאי, לכניסה לרשימת המתנה, אנא צרו קשר!';

 return $text;

}

add_filter( 'woocommerce_out_of_stock_message', 'puri_out_of_stock_message', 999);
​^(-?\d*\.?\d+)(\+|-|\/|\*)(-?\d*\.?\d+)$
<div class="wrapper">

  <svg class="cyclist" width="2" height="24" viewBox="0 0 24 24">

  <path d="M,20.5A3.5,3.5 0 0,1 1.5,1A3.5,3.5 0 0,1 5,13.5A3.5,3.5 0 0,1 .5,17A3.5,3.5 0 0,1 5,20.5M5,12A5,5 0 0,0 0,17A5,5 0 0,0 5,22A5,5 0 0,0 10,17A5,5 0 0,0 5,12M14.8,10H19V8.2H15.8L13.8,4.93C13.57,4.43 13,4.1 12.4,4.1C11.93,4.1 11.5,4.29 11.2,4.6L7.5,8.29C7.19,8.6 7,9 7,9.5C7,10.13 7.33,10.66 7.85,10.97L11.2,13V18H13V11.5L10.75,9.85L13.07,7.5M19,20.5A3.5,3.5 0 0,1 15.5,17A3.5,3.5 0 0,1 19,13.5A3.5,3.5 0 0,1 22.5,17A3.5,3.5 0 0,1 19,20.5M19,12A5,5 0 0,0 14,17A5,5 0 0,0 19,22A5,5 0 0,0 24,17A5,5 0 0,0 19,12M16,4.8C17,4.8 17.8,4 17.8,3C17.8,2 17,1.2 16,1.2C15,1.2 14.2,2 14.2,3C14.2,4 15,4.8 16,4.8Z"></path>
4
</svg>
5
<svg class="hill" width="942" height="343" viewBox="0 0 942 343" fill="#000" xmlns="http://www.w3.org/2000/svg">
6
<path d="M129.069 240.15C101.054 252.632 64.034 259.999 0 259V343H942V0C923.49 108.841 845.949 228.167 801.425 268.608C781.416 286.783 743.395 307.552 666.854 257.125C590.313 206.699 552.793 138.298 478.754 138.798C404.715 139.297 387.206 221.677 341.181 257.125C295.157 292.574 245.13 270.606 210.612 257.125C176.093 243.645 157.083 227.668 129.069 240.15Z"/>
7
</svg>
8
</div>
$count: 0;

​

:root {

  --animation-time: 1s;

  --animation-timging-function: cubic-bezier(0.2, 0.61, 0.355, 1);
6
  --color-primary: #e1e63;

  --color-primary-hover: #ff50c;
8
}
9
​

html {

  font-size: 10px;

}

​

body {
15
  display: flex;

  overflow: hidden;

  align-items: center;

  justify-content: center;

  width: 100vw;

  height: 100vh;
<h1> The Life of a </h1>

<h2> Coder </h2>

<P> <a href=https://www.noisli.com>noisli</a> for happy coding.</P>

<p> Keep your code close but your playlist closer.</p>

​
django-admin startproject mysite
 
python manage.py startapp myapp
import pandas as pd
import matplotlib.pyplot as plt

from pandas_profiling import ProfileReport
profile = ProfileReport(gabijos, title='Gabijos g.', html={'style':{'full_width':True}})
profile.to_file("gabijos.html")

​import wordcloud
import pandas as pd
import matplotlib.pyplot as plt

# text = open(path.join(d, 'constitution.txt')).read()

# # Generate a word cloud image
# wordcloud = WordCloud().generate(text)

# cloud = wordcloud.WordCloud(max_words = 2000, width = 1600,height = 900).generate(' '.join(data.Sentence))

# plt.figure(figsize=(20,12))
# plt.imshow(cloud)
# plt.axis("off")
# plt.savefig("WordCloudGoT.png")

data = pd.read_excel('aruodas20210401.xlsx')


cloud = wordcloud.WordCloud(max_words = 20, width = 1600,height = 900).generate(' '.join(data['Aprašymas']))

plt.figure(figsize=(20,12))
plt.imshow(cloud)
plt.axis("off")
plt.savefig("WordCloudGoT.png")
/* Basic styles */

*,

*::before,

*::after {

  box-sizing: border-box;

}

​

:root{

    --bg-color: #D8D8D8;

}

​

body {

  display: flex;

  align-items: center;

  justify-content: center;

  overflow: hidden;

  width: 100vw;

  height: 100vh;
<h1 class="home-title">

  <span>Simple text reveal with css</span>

  <span>using pseudo elements</span>

  <span>y mierdas</span>

</h1>

​
@keyframes slide{

  0% {

    width: 0%;

  }

  

  40%, 0% {

    width: 100%;

  }

  
10
}

​

body {

  margin: 0;

  padding: 0;

}

​

.container {

  display: flex;
<div class="container">

  <div class="outer">

    <h1 class="text">I'm a Frontend Developer</h1>

    <div class="inner">

      <h1 class="text">I'm a Frontend Developer</h1>

    </div>

  </div>

</div>

​
​

​

  .section img { 

    left: 0; 

    position:absolute; 

    top: 0; 

}

​

 .section img.one {opacity:0;filter:alpha(opacity=0);}

​

  .section:hover img.one {opacity:1;filter:alpha(opacity=100);}

​

  .section:hover img.two {opacity:0;filter:alpha(opacity=0);}
<a class="section" href="#">

  <img class="one" src="https://banner2.cleanpng.com/20180706/pif/kisspng-cat-red-fox-mammal-paw-dog-angry-chibi-5bfbeaf260060.276995815309042391557.jpg" width=150px />
3
  <img class="two" src="https://w7.pngwing.com/pngs/964/900/png-transparent-tom-tom-cat-jerry-mouse-tom-and-jerry-drawing-tom-and-jerry-mammal-heroes-cat-like-mammal.png" width=150px />
4
</a>
module.exports = leftpad;
​
function leftpad(str, len, ch) {
  str = String(str);
  var i = -1;
​
  if (!ch && ch !== 0) ch = ' ';
​
  len = len - str.length;
​
  while (i++ < len) {
    str = ch + str;
  }
  return str;
}
<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
​
<h1>This is a Heading</h1>
<p>This is a paragraph.</p>
​
</body>
</html>
​
<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
​
<h1>This is a Heading</h1>
<p>This is a paragraph.</p>
​
</body>
</html>
​
<!DOCTYPE html>
<html>
<head>
<title>Pagefsfn</title>
</head>
<body>
​
<h1>This is a Heading</h1>
<p>This is a paragraph.</p>
​
</body>
</html>
​
<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
​
<h1>This is a Heading</h1>
<p>This is a paragraph.</p>
​
</body>
</html>
​
.u-center-text {

  text-align: center !important;

}

​

.u-margin-bottom-small {

  margin-bottom: 1.5rem !important;

}

​

.u-margin-bottom-medium {

  margin-bottom: 4rem !important;

}

​

.u-margin-top-big {

  margin-top: 5rem !important;

}

​
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<style>
.vl {
  border-left: 6px solid green;
  height: 500px;
  position: absolute;
  left: 50%;
  margin-left: -3px;
  top: 0;
}
</style>
</head>
<body>
​
<h2>Vertical Line</h2>
​
<div class="vl"></div>
​
</body>
</html>
​
<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
​
<h1>My First Heading</h1>
<p>My first paragraph.</p>
​
</body>
</html>
​
<!-- Facebook Pixel Code -->
<script>
!function(f,b,e,v,n,t,s)
{if(f.fbq)return;n=f.fbq=function(){n.callMethod?
n.callMethod.apply(n,arguments):n.queue.push(arguments)};
if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';
n.queue=[];t=b.createElement(e);t.async=!0;
t.src=v;s=b.getElementsByTagName(e)[0];
s.parentNode.insertBefore(t,s)}(window, document,'script',
'https://connect.facebook.net/en_US/fbevents.js');
fbq('init', '766974780896089');
fbq('track', 'PageView');
</script>
<noscript><img height="1" width="1" style="display:none"
src="https://www.facebook.com/tr?id=766974780896089&ev=PageView&noscript=1"
/></noscript>
<!-- End Facebook Pixel Code -->
​
​<!-- Facebook Pixel Code -->
<script>
  !function(f,b,e,v,n,t,s)
  {if(f.fbq)return;n=f.fbq=function(){n.callMethod?
  n.callMethod.apply(n,arguments):n.queue.push(arguments)};
  if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';
  n.queue=[];t=b.createElement(e);t.async=!0;
  t.src=v;s=b.getElementsByTagName(e)[0];
  s.parentNode.insertBefore(t,s)}(window, document,'script',
  'https://connect.facebook.net/en_US/fbevents.js');
  fbq('init', '766974780896089');
  fbq('track', 'PageView');
</script>
<noscript><img height="1" width="1" style="display:none"
  src="https://www.facebook.com/tr?id=766974780896089&ev=PageView&noscript=1"
/></noscript>
<!-- End Facebook Pixel Code -->
async function retryRequest(promiseFunc, nrOfRetries) {

  // Write your code here

}

        

let hasFailed = false;

function getUserInfo() {

  return new Promise((resolve, reject) => {

    if(!hasFailed) {

      hasFailed = true;

      reject("Exception!");

    } else {

      resolve("Fetched user!");

    }

  });

}

let promise = retryRequest(getUserInfo, 3);

if(promise) {

  promise.then((result) => console.log(result))

  .catch((error) => console.log("Error!"));

}

module.exports.retryRequest = retryRequest;
let fs;

​

function fileExistsSync(name) {

  return fs.existsSync(name);

}

​

fileExistsSync = fileExistsSync;
@import url(https://fonts.googleapis.com/css?family=Bitter);

​

* {

  box-sizing: border-box;

}

​

html {

  text-align: center;

  padding-top: 50px;

  background: url(https://dl.dropbox.com/s/mz2pjouq8xqw45k/wood_1.png?dl=1);

}

​

blockquote {

  position: relative;

  display: inline-block;

  background: #eee;

  padding: 40px 30px 30px 60px;

  border-radius: 10px;

  font-family: 'Bitter', serif;

  color: #333;

  text-align: left;

  

  box-shadow: 1px 1px 1px #999,

              2px 2px 1px #999,

              3px 3px 1px #999;

  transition-duration: .3s;
//function that returns multiple values

function getTopTwoColors() {

    return ["blue", "pink"];

}

var topTwoColors=getTopTwoColors();

var firstValue=topTwoColors[0]; //get first return value

var secondValue=topTwoColors[1]; //get second return value
rclone config - 以控制会话的形式添加rclone的配置,配置保存在.rclone.conf文件中。
rclone copy - 将文件从源复制到目的地址,跳过已复制完成的。
rclone sync - 将源数据同步到目的地址,只更新目的地址的数据。
rclone move - 将源数据移动到目的地址。
rclone delete - 删除指定路径下的文件内容。
rclone purge - 清空指定路径下所有文件数据。
rclone mkdir - 创建一个新目录。
rclone rmdir - 删除空目录。
rclone check - 检查源和目的地址数据是否匹配。
rclone ls - 列出指定路径下所有的文件以及文件大小和路径。
rclone lsd - 列出指定路径下所有的目录/容器/桶。
rclone lsl - 列出指定路径下所有文件以及修改时间、文件大小和路径。
rclone md5sum - 为指定路径下的所有文件产生一个md5sum文件。
rclone sha1sum - 为指定路径下的所有文件产生一个sha1sum文件。
rclone size - 获取指定路径下,文件内容的总大小。.
rclone version - 查看当前版本。
rclone cleanup - 清空remote。
rclone dedupe - 交互式查找重复文件,进行删除/重命名操作。
 
rclone move Gdrive1:/Private Gdrive2:/Private
or
rclone copy Gdrive1:/SFW Gdrive2:/SFW
or
rclone sync Gdrive1:/NSFW Gdrive2:/NSFW	
 

rclone copy        复制
rclone move        移动,如果要在移动后删除空源目录,加上 --delete-empty-src-dirs 参数
rclone sync        同步:将源目录同步到目标目录,只更改目标目录
rclone size        查看网盘文件占用大小
rclone delete        删除路径下的文件内容
rclone purge        删除路径及其所有文件内容
rclone mkdir        创建目录
rclone rmdir        删除目录
rclone rmdirs        删除指定环境下的空目录。如果加上 --leave-root 参数,则不会删除根目录
rclone check        检查源和目的地址数据是否匹配
rclone ls        列出指定路径下的所有的文件以及文件大小和路径
rclone lsl        比上面多一个显示上传时间
rclone lsd        列出指定路径下的目录
rclone lsf        列出指定路径下的目录和文件

# 复制到网盘,并显示实时传输进度,设置并行上传数为8
 
rclone copy -P /home/SunPma GD:/home/SunPma --transfers=8
 
# 如果需要服务端对服务端的传输可加以下参数(不消耗本地流量)
 
rclone copy 配置名称:网盘路径 配置名称:网盘路径 --drive-server-side-across-configs

rclone 有 4 个级别的日志记录,ERROR,NOTICE,INFO 和 DEBUG。默认情况下,rclone 将生成 ERROR 和 NOTICE 级别消息。

-q - rclone将仅生成 ERROR 消息。
-v - rclone将生成 ERROR,NOTICE 和 INFO 消息,推荐此项。
-vv - rclone 将生成 ERROR,NOTICE,INFO和 DEBUG 消息。
--log-level LEVEL - 标志控制日志级别。
​.icon-interactive {
	fill: #6A6976;
	fill-rule: evenodd;
	height: 32px;
	width:32px;
	background:none;
	cursor:pointer;
}

.icon-interactive:hover {
	fill: #363545;
	height: 32px;
	width:32px;
	background:#e2e2e7;
	border-radius: 4px;
}

.icon-interactive:active {
	fill: #0D6AA8;
	height: 32px;
	width:32px;
	background:#CFE1EE;
	border-radius: 4px;
	
}
​fetch('https://jsonplaceholder.typicode.com/todos/1')
      .then(resultado => {
  	return resultado.json();
})
      .then(resultadoFinal => {
  	console.log(resultadoFinal)
});


#include <iostream>
using namespace std;
​
int main() {
  cout << "Hello World!";
  return 0;
}
​
<!DOCTYPE html>
<html>
<body>
​
<p>Click the button to create a Text Field.</p>
​
<button onclick="myFunction()">Try it</button>
​
<script>
function myFunction() {
  var x = document.createElement("INPUT");
  x.setAttribute("type", "text");
  x.setAttribute("value", "Hello World!");
  document.body.appendChild(x);
}
</script>
​
</body>
</html>
​
$(function()

  {

    $('#myform').validate(

      {

        rules:

        {

          Color:{ required:true }

        },

        messages:

        {

          Color:

          {

            required:"Please select a Color<br/>"

          }

        },

        errorPlacement: function(error, element) 

        {

            if ( element.is(":radio") ) 

            {

                error.appendTo( element.parents('.container') );

            }

            else 

            { // This is the default behavior 

                error.insertAfter( element );
<!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<style>
body {
  font-family: Arial;
}
​
* {
  box-sizing: border-box;
}
​
.openBtn {
  background: #f1f1f1;
  border: none;
  padding: 10px 15px;
  font-size: 20px;
  cursor: pointer;
}
​
.openBtn:hover {
  background: #bbb;
}
​
.overlay {
  height: 100%;
  width: 100%;
  display: none;
  position: fixed;
  z-index: 1;
  top: 0;
  left: 0;
  background-color: rgb(0,0,0);
  background-color: rgba(0,0,0, 0.9);
}
​
.overlay-content {
  position: relative;
  top: 46%;
{

  queryArtists(byName:"Red Hot Chili Peppers") {

    name

    id

    image

    albums {

      id

    }

  }

}

​

​
{

  queryArtists(byName:"Red Hot Chili Peppers") {

    name

    id

    image

  }

}

​
<!DOCTYPE html>
<html>
<head>
<style> 
p:nth-child(2) {
  background: red;
}
</style>
</head>
<body>
​
<p>The first paragraph.</p>
<p>The second paragraph.</p>
<p>The third paragraph.</p>
<p>The fourth paragraph.</p>
​
<p><b>Note:</b> Internet Explorer 8 and earlier versions do not support the :nth-child() selector.</p>
​
</body>
</html>
​
star

Mon Jul 12 2021 19:57:02 GMT+0000 (UTC) https://online.alra.pt/alrateste/wp-admin/theme-editor.php?file

#undefined
star

Mon Jul 12 2021 19:55:37 GMT+0000 (UTC) https://online.alra.pt/alrateste/wp-admin/theme-editor.php?file

#undefined
star

Mon Jul 12 2021 12:56:43 GMT+0000 (UTC) edconnect.com

#undefined ##array ##2d-array ##asychronousfunction
star

Sun Jul 11 2021 17:13:54 GMT+0000 (UTC) https://codepen.io/philcheng/pen/YWyYwG

#undefined
star

Thu Jul 08 2021 08:20:50 GMT+0000 (UTC) edconnect.com

#undefined ##array ##2d-array
star

Thu Jul 01 2021 14:39:20 GMT+0000 (UTC) https://runkit.com/60c0cdb20a7ce300136b43ef/60ddd160f073b0001ae92fe6

#undefined
star

Tue Jun 22 2021 10:28:31 GMT+0000 (UTC) https://regex101.com/r/qtEg6H/3

#undefined
star

Mon Jun 21 2021 07:44:49 GMT+0000 (UTC) https://www.codingninjas.com/codestudio/problems/serialise-deserialise-a-binary-tree_920328?leftPanelTab

#undefined
star

Sat Jun 19 2021 16:08:40 GMT+0000 (UTC) https://www.kikos.co.il/wp-admin/admin.php?page

#undefined
star

Sun Jun 13 2021 13:41:07 GMT+0000 (UTC) https://codepen.io/amiraamin12/pen/Popxqep?editors

#undefined
star

Sun Jun 13 2021 13:25:25 GMT+0000 (UTC) https://codepen.io/amiraamin12/pen/Popxqep?editors

#undefined
star

Sun Jun 13 2021 13:16:26 GMT+0000 (UTC) https://codepen.io/amiraamin12/pen/Popxqep?editors

#undefined
star

Sun Jun 13 2021 10:54:47 GMT+0000 (UTC) https://codepen.io/amiraamin12/pen/Popxqep?editors

#undefined
star

Sun Jun 13 2021 10:38:32 GMT+0000 (UTC) https://codepen.io/amiraamin12/pen/Popxqep?editors

#undefined
star

Sun Jun 13 2021 06:11:22 GMT+0000 (UTC) https://codepen.io/pen

#undefined
star

Mon May 17 2021 12:57:28 GMT+0000 (UTC) https://regex101.com/

#undefined
star

Thu Apr 29 2021 08:09:38 GMT+0000 (UTC) https://codepen.io/Chokcoco/pen/dyNaZea

#undefined
star

Thu Apr 29 2021 08:06:38 GMT+0000 (UTC) https://codepen.io/Chokcoco/pen/xxgMPzJ

#undefined
star

Wed Apr 28 2021 19:20:03 GMT+0000 (UTC) https://practicum.yandex.com/trainer/web/lesson/984ec6da-05e7-4da3-ae87-220fd96e4ce4/task/ce03e248-f8fa-4445-bfaf-465307085e9c/

#undefined
star

Wed Apr 21 2021 08:08:37 GMT+0000 (UTC) https://regex101.com/

#undefined
star

Fri Apr 16 2021 08:52:49 GMT+0000 (UTC) https://codepen.io/hanihsdd/pen/KKaQxdX

#undefined
star

Wed Apr 07 2021 16:50:10 GMT+0000 (UTC)

#undefined #python #pandas
star

Wed Apr 07 2021 16:40:56 GMT+0000 (UTC) https://pandas-profiling.github.io/pandas-profiling/docs/master/rtd/

#undefined #python #pandas
star

Tue Apr 06 2021 20:30:27 GMT+0000 (UTC) http://localhost:8888/notebooks/Untitled2.ipynb?kernel_name

#undefined
star

Sun Mar 14 2021 11:12:50 GMT+0000 (UTC) https://codepen.io/aruizh/pen/OBqxVj

#undefined
star

Sun Mar 14 2021 11:12:43 GMT+0000 (UTC) https://codepen.io/aruizh/pen/OBqxVj

#undefined
star

Sun Mar 14 2021 10:58:43 GMT+0000 (UTC) https://codepen.io/rohitgd/pen/mwbwmQ

#undefined
star

Sun Mar 14 2021 10:58:31 GMT+0000 (UTC) https://codepen.io/rohitgd/pen/mwbwmQ

#undefined
star

Wed Mar 10 2021 04:58:51 GMT+0000 (UTC) https://codepen.io/mikaela-matatko/pen/bGeJvvz

#undefined
star

Wed Mar 10 2021 04:58:43 GMT+0000 (UTC) https://codepen.io/mikaela-matatko/pen/bGeJvvz

#undefined
star

Wed Mar 10 2021 04:58:37 GMT+0000 (UTC) https://codepen.io/mikaela-matatko/pen/bGeJvvz

#undefined
star

Sun Mar 07 2021 04:52:47 GMT+0000 (UTC) https://codepen.io/pen/

#undefined
star

Wed Feb 17 2021 17:01:38 GMT+0000 (UTC) https://ray.so/

#undefined
star

Wed Feb 17 2021 08:53:45 GMT+0000 (UTC) https://www.w3schools.com/html/tryit.asp?filename

#undefined
star

Wed Feb 17 2021 08:53:10 GMT+0000 (UTC) https://www.w3schools.com/html/tryit.asp?filename

#undefined
star

Wed Feb 17 2021 08:52:29 GMT+0000 (UTC) https://www.w3schools.com/html/tryit.asp?filename

#undefined
star

Wed Feb 17 2021 08:52:13 GMT+0000 (UTC) https://www.w3schools.com/html/tryit.asp?filename

#undefined
star

Thu Feb 11 2021 09:52:50 GMT+0000 (UTC) https://github.com/razanavi/check/new/main

#undefined
star

Fri Feb 05 2021 04:40:13 GMT+0000 (UTC) https://codepen.io/JeremyWink/pen/oNvybqX

#undefined
star

Thu Feb 04 2021 18:56:03 GMT+0000 (UTC) https://www.w3schools.com/howto/tryit.asp?filename

#undefined
star

Wed Feb 03 2021 08:57:19 GMT+0000 (UTC) https://www.w3schools.com/html/tryit.asp?filename

#undefined
star

Wed Jan 27 2021 06:56:15 GMT+0000 (UTC) https://theedgetofreedom.com/wp-admin/options-general.php?page

#undefined
star

Wed Jan 27 2021 06:44:57 GMT+0000 (UTC) https://theedgetofreedom.com/wp-admin/options-general.php?page

#undefined
star

Tue Jan 12 2021 12:42:12 GMT+0000 (UTC) https://app.testdome.com/t/25b56554052d47a590682ed2866474b9

#undefined
star

Tue Jan 12 2021 12:38:14 GMT+0000 (UTC) https://app.testdome.com/t/25b56554052d47a590682ed2866474b9

#undefined
star

Thu Jan 07 2021 08:54:05 GMT+0000 (UTC) https://codepen.io/lukasdietrich/pen/KLJjy

#undefined
star

Wed Dec 30 2020 15:01:32 GMT+0000 (UTC) https://codepen.io/pen/tour/welcome/start

#undefined
star

Sun Nov 29 2020 14:36:26 GMT+0000 (UTC) https://www.codegrepper.com/code-examples/delphi/return+2+objects+from+function+typescript

#undefined
star

Tue Nov 10 2020 07:16:25 GMT+0000 (UTC) https://www.codegrepper.com/code-examples/javascript/add+property+to+object+javascript+using+".map()"

#undefined
star

Fri Oct 30 2020 07:18:18 GMT+0000 (UTC) https://blog.jialezi.net/?post

#undefined
star

Wed Oct 28 2020 22:15:39 GMT+0000 (UTC)

#undefined
star

Sat Oct 24 2020 18:15:17 GMT+0000 (UTC) https://es6console.com/

#undefined
star

Wed Sep 16 2020 20:35:23 GMT+0000 (UTC) https://www.w3schools.com/cpp/showcpp.asp?filename=demo_helloworld

#undefined
star

Thu Aug 06 2020 14:18:32 GMT+0000 (UTC) https://www.w3schools.com/jsref/tryit.asp?filename=tryjsref_text_create

#undefined
star

Tue Jul 07 2020 20:15:22 GMT+0000 (UTC) https://codepen.io/prasanthmj/pen/HGmad

#undefined
star

Tue Jun 30 2020 14:22:23 GMT+0000 (UTC) https://www.w3schools.com/howto/tryit.asp?filename=tryhow_js_fullscreen_search

#undefined
star

Fri Jun 05 2020 20:56:50 GMT+0000 (UTC) https://spotify-graphql-server.herokuapp.com/graphql?query={ queryArtists(byName:"Red Hot Chili Peppers") { name id image albums { id } }}

#undefined
star

Fri Jun 05 2020 15:54:06 GMT+0000 (UTC) https://spotify-graphql-server.herokuapp.com/graphql?query={ queryArtists(byName:"Red Hot Chili Peppers") { name id image }}

#undefined
star

Fri May 29 2020 13:53:32 GMT+0000 (UTC) https://www.w3schools.com/cssref/tryit.asp?filename=trycss3_nth-child

#undefined

Save snippets that work with our extensions

Available in the Chrome Web Store Get Firefox Add-on Get VS Code extension