/**
 * \addtogroup BSP
 * \{
 * \addtogroup DEVICES
 * \{
 * \addtogroup GPIO
 * \{
 * \brief GPIO Control
 */

/**
 *****************************************************************************************
 *
 * @file hw_gpio.h
 *
 * @brief Definition of API for the GPIO Low Level Driver.
 *
 * Copyright (c) 2016, Dialog Semiconductor
 * All rights reserved.
 * Redistribution and use in source and binary forms, with or without modification,
 * are permitted provided that the following conditions are met:
 * 1. Redistributions of source code must retain the above copyright notice,
 *    this list of conditions and the following disclaimer.
 * 2. Redistributions in binary form must reproduce the above copyright notice,
 *    this list of conditions and the following disclaimer in the documentation
 *    and/or other materials provided with the distribution.
 * 3. Neither the name of the copyright holder nor the names of its contributors
 *    may be used to endorse or promote products derived from this software without
 *    specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
 * IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
 * INDIRECT, INCIDENTAL,  SPECIAL,  EXEMPLARY,  OR CONSEQUENTIAL DAMAGES (INCLUDING,
 * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
 * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
 * OF THE POSSIBILITY OF SUCH DAMAGE.
 *
 *
 *****************************************************************************************
 */

#ifndef HW_GPIO_H_
#define HW_GPIO_H_

#if dg_configUSE_HW_GPIO

#include <stdbool.h>
#include <stdint.h>
#include <sdk_defs.h>

/* GPIO layout definitions */

/** Number of GPIO ports available */
#define HW_GPIO_NUM_PORTS       (5)
/** Number of GPIO pins available (cumulative) */
#define HW_GPIO_NUM_PINS        (HW_GPIO_PORT_0_NUM_PINS + HW_GPIO_PORT_1_NUM_PINS + \
                                        HW_GPIO_PORT_2_NUM_PINS + HW_GPIO_PORT_3_NUM_PINS + \
                                        HW_GPIO_PORT_4_NUM_PINS)
/** Number of GPIO pins available in port 0 */
#define HW_GPIO_PORT_0_NUM_PINS (8)
/** Number of GPIO pins available in port 1 */
#define HW_GPIO_PORT_1_NUM_PINS (8)
/** Number of GPIO pins available in port 2 */
#define HW_GPIO_PORT_2_NUM_PINS (5)
/** Number of GPIO pins available in port 3 */
#define HW_GPIO_PORT_3_NUM_PINS (8)
/** Number of GPIO pins available in port 4 */
#define HW_GPIO_PORT_4_NUM_PINS (8)
/** Number of pins in each GPIO port */
extern const uint8_t hw_gpio_port_num_pins[HW_GPIO_NUM_PORTS];

/**
 * \brief GPIO input/output mode
 *
 */
typedef enum {
        HW_GPIO_MODE_INPUT = 0,                 /**< GPIO as an input */
        HW_GPIO_MODE_INPUT_PULLUP = 0x100,      /**< GPIO as an input with pull-up */
        HW_GPIO_MODE_INPUT_PULLDOWN = 0x200,    /**< GPIO as an input with pull-down */
        HW_GPIO_MODE_OUTPUT = 0x300,            /**< GPIO as an (implicitly push-pull) output */
        HW_GPIO_MODE_OUTPUT_PUSH_PULL = 0x300,  /**< GPIO as an (explicitly push-pull) output */
        HW_GPIO_MODE_OUTPUT_OPEN_DRAIN = 0x700, /**< GPIO as an open-drain output */
} HW_GPIO_MODE;

/**
 * \brief GPIO power source
 *
 */
typedef enum {
        HW_GPIO_POWER_V33 = 0,          /**< V33 (3.3 V) power rail */
        HW_GPIO_POWER_VDD1V8P = 1,      /**< VDD1V8P (1.8 V) power rail */
} HW_GPIO_POWER;

/**
 * \brief GPIO port number
 *
 */
typedef enum {
        HW_GPIO_PORT_0 = 0,     /**< GPIO Port 0 */
        HW_GPIO_PORT_1 = 1,     /**< GPIO Port 1 */
        HW_GPIO_PORT_2 = 2,     /**< GPIO Port 2 */
        HW_GPIO_PORT_3 = 3,     /**< GPIO Port 3 */
        HW_GPIO_PORT_4 = 4      /**< GPIO Port 4 */
} HW_GPIO_PORT;

/**
 * \brief GPIO pin number
 *
 */
typedef enum {
        HW_GPIO_PIN_0 = 0,      /**< GPIO Pin 0 */
        HW_GPIO_PIN_1 = 1,      /**< GPIO Pin 1 */
        HW_GPIO_PIN_2 = 2,      /**< GPIO Pin 2 */
        HW_GPIO_PIN_3 = 3,      /**< GPIO Pin 3 */
        HW_GPIO_PIN_4 = 4,      /**< GPIO Pin 4 */
        HW_GPIO_PIN_5 = 5,      /**< GPIO Pin 5 */
        HW_GPIO_PIN_6 = 6,      /**< GPIO Pin 6 */
        HW_GPIO_PIN_7 = 7,      /**< GPIO Pin 7 */
} HW_GPIO_PIN;

/**
 * \brief GPIO function
 *
 */
typedef enum {
        HW_GPIO_FUNC_GPIO = 0,                  /**< GPIO */
        HW_GPIO_FUNC_UART_RX = 1,               /**< GPIO as UART RX */
        HW_GPIO_FUNC_UART_TX = 2,               /**< GPIO as UART TX */
        HW_GPIO_FUNC_UART_IRDA_RX = 3,          /**< GPIO as UART IRDA RX */
        HW_GPIO_FUNC_UART_IRDA_TX = 4,          /**< GPIO as UART IRDA TX */
        HW_GPIO_FUNC_UART2_RX = 5,              /**< GPIO as UART2 RX */
        HW_GPIO_FUNC_UART2_TX = 6,              /**< GPIO as UART2 TX */
        HW_GPIO_FUNC_UART2_IRDA_RX = 7,         /**< GPIO as UART2 IRDA RX */
        HW_GPIO_FUNC_UART2_IRDA_TX = 8,         /**< GPIO as UART2 IRDA TX */
        HW_GPIO_FUNC_UART2_CTSN = 9,            /**< GPIO as UART2 CTSN */
        HW_GPIO_FUNC_UART2_RTSN = 10,           /**< GPIO as UART2 RTSN */
        HW_GPIO_FUNC_SPI_DI = 11,               /**< GPIO as SPI DI */
        HW_GPIO_FUNC_SPI_DO = 12,               /**< GPIO as SPI DO */
        HW_GPIO_FUNC_SPI_CLK = 13,              /**< GPIO as SPI CLK */
        HW_GPIO_FUNC_SPI_EN = 14,               /**< GPIO as SPI EN */
        HW_GPIO_FUNC_SPI2_DI = 15,              /**< GPIO as SPI2 DI */
        HW_GPIO_FUNC_SPI2_DO = 16,              /**< GPIO as SPI2 DO */
        HW_GPIO_FUNC_SPI2_CLK = 17,             /**< GPIO as SPI2 CLK */
        HW_GPIO_FUNC_SPI2_EN = 18,              /**< GPIO as SPI2 EN */
        HW_GPIO_FUNC_I2C_SCL = 19,              /**< GPIO as I2C SCL */
        HW_GPIO_FUNC_I2C_SDA = 20,              /**< GPIO as I2C SDA */
        HW_GPIO_FUNC_I2C2_SCL = 21,             /**< GPIO as I2C2 SCL */
        HW_GPIO_FUNC_I2C2_SDA = 22,             /**< GPIO as I2C2 SDA */
        HW_GPIO_FUNC_PWM0 = 23,                 /**< GPIO as PWM0 */
        HW_GPIO_FUNC_PWM1 = 24,                 /**< GPIO as PWM1 */
        HW_GPIO_FUNC_PWM2 = 25,                 /**< GPIO as PWM2 */
        HW_GPIO_FUNC_PWM3 = 26,                 /**< GPIO as PWM3 */
        HW_GPIO_FUNC_PWM4 = 27,                 /**< GPIO as PWM4 */
        HW_GPIO_FUNC_BLE_DIAG = 28,             /**< GPIO as BLE DIAG */
        HW_GPIO_FUNC_FTDF_DIAG = 29,            /**< GPIO as FTDF DIAG */
        HW_GPIO_FUNC_PCM_DI = 30,               /**< GPIO as PCM DI */
        HW_GPIO_FUNC_PCM_DO = 31,               /**< GPIO as PCM DO */
        HW_GPIO_FUNC_PCM_FSC = 32,              /**< GPIO as PCM FSC */
        HW_GPIO_FUNC_PCM_CLK = 33,              /**< GPIO as PCM CLK */
        HW_GPIO_FUNC_PDM_DI = 34,               /**< GPIO as PDM DI */
        HW_GPIO_FUNC_PDM_DO = 35,               /**< GPIO as PDM DO */
        HW_GPIO_FUNC_PDM_CLK = 36,              /**< GPIO as PDM CLK */
        HW_GPIO_FUNC_USB_SOF = 37,              /**< GPIO as USB SOF */
        HW_GPIO_FUNC_ADC = 38,                  /**< GPIO as ADC */
        HW_GPIO_FUNC_USB = 38,                  /**< GPIO as USB */
        HW_GPIO_FUNC_QSPI = 38,                 /**< GPIO as QSPI */
        HW_GPIO_FUNC_XTAL32 = 38,               /**< GPIO as XTAL32 */
        HW_GPIO_FUNC_QUADEC_XA = 39,            /**< GPIO as QUADEC XA */
        HW_GPIO_FUNC_QUADEC_XB = 40,            /**< GPIO as QUADEC XB */
        HW_GPIO_FUNC_QUADEC_YA = 41,            /**< GPIO as QUADEC YA */
        HW_GPIO_FUNC_QUADEC_YB = 42,            /**< GPIO as QUADEC YB */
        HW_GPIO_FUNC_QUADEC_ZA = 43,            /**< GPIO as QUADEC ZA */
        HW_GPIO_FUNC_QUADEC_ZB = 44,            /**< GPIO as QUADEC ZB */
        HW_GPIO_FUNC_IR_OUT = 45,               /**< GPIO as IR OUT */
        HW_GPIO_FUNC_BREATH = 46,               /**< GPIO as BREATH */
        HW_GPIO_FUNC_KB_ROW = 47,               /**< GPIO as KB ROW */
        HW_GPIO_FUNC_COEX_EXT_ACT0 = 48,        /**< GPIO as COEX EXT ACT0 */
        HW_GPIO_FUNC_COEX_EXT_ACT1 = 49,        /**< GPIO as COEX EXT ACT1 */
        HW_GPIO_FUNC_COEX_SMART_ACT = 50,       /**< GPIO as COEX SMART ACT */
        HW_GPIO_FUNC_COEX_SMART_PRI = 51,       /**< GPIO as COEX SMART PRI */
        HW_GPIO_FUNC_CLOCK = 52,                /**< GPIO as CLOCK */
        HW_GPIO_FUNC_ONESHOT = 53,              /**< GPIO as ONESHOT */
        HW_GPIO_FUNC_PWM5 = 54,                 /**< GPIO as PWM5 */
        HW_GPIO_FUNC_PORT0_DCF = 55,            /**< GPIO as PORT0 DCF */
        HW_GPIO_FUNC_PORT1_DCF = 56,            /**< GPIO as PORT1 DCF */
        HW_GPIO_FUNC_PORT2_DCF = 57,            /**< GPIO as PORT2 DCF */
        HW_GPIO_FUNC_PORT3_DCF = 58,            /**< GPIO as PORT3 DCF */
        HW_GPIO_FUNC_PORT4_DCF = 59,            /**< GPIO as PORT4 DCF */
        HW_GPIO_FUNC_RF_ANT_TRIM0 = 60,         /**< GPIO as RF ANT TRIM0 */
        HW_GPIO_FUNC_RF_ANT_TRIM1 = 61,         /**< GPIO as RF ANT TRIM1 */
        HW_GPIO_FUNC_RF_ANT_TRIM2 = 62          /**< GPIO as RF ANT TRIM2 */
} HW_GPIO_FUNC;

/**
 * \brief GPIO pin configuration
 *
 * It's recommended to use \p HW_GPIO_PINCONFIG and \p HW_GPIO_PINCONFIG_RESERVE to set pin entries.
 * Each configuration must be terminated using \p HW_GPIO_PINCONFIG_END macro.
 *
 */
typedef struct {
        uint8_t         pin;     /**< pin name, high-nibble is port number and low-nibble is pin */
        HW_GPIO_MODE    mode;    /**< pin mode */
        HW_GPIO_FUNC    func;    /**< pin function */
        bool            high;    /**< initial pin state, true for high and false for low */
        bool            reserve; /*<< true if pin should be also reserved */
} __attribute__((packed)) gpio_config;

/**
 * \brief GPIO pin configuration for \p gpio_config
 *
 * \p xport and \p xpin are specified as symbols from \p HW_GPIO_PORT and \p HW_GPIO_PIN enums
 * respectively or more conveniently as plain numeric values.
 * \p xmode and \p xfunc have the same values as defined in \p HW_GPIO_MODE and \p HW_GPIO_FUNC enums
 * respectively, except they have prefix stripped.
 *
 * \param [in] xport port number
 * \param [in] xpin pin number
 * \param [in] xmode pin mode
 * \param [in] xfunc pin function
 * \param [in] xhigh true for high state, false otherwise
 *
 */
#define HW_GPIO_PINCONFIG(xport, xpin, xmode, xfunc, xhigh) \
        {                                               \
                .pin = (xport << 4) | (xpin & 0x0F),    \
                .mode = HW_GPIO_MODE_ ## xmode,         \
                .func = HW_GPIO_FUNC_ ## xfunc,         \
                .high = xhigh,                          \
                .reserve = false,                       \
        }

/**
 * \brief GPIO pin configuration and reservation for \p gpio_config
 *
 * This macro is virtually identical to \p HW_GPIO_PINCONFIG, except it also reserves pin.
 *
 * \param [in] xport port number
 * \param [in] xpin pin number
 * \param [in] xmode pin mode
 * \param [in] xfunc pin function
 * \param [in] xhigh true for high state, false otherwise
 *
 * \sa HW_GPIO_PINCONFIG
 *
 */
#define HW_GPIO_PINCONFIG_RESERVE(xport, xpin, xmode, xfunc, xhigh) \
        {                                               \
                .pin = (xport << 4) | (xpin & 0x0F),    \
                .mode = HW_GPIO_MODE_ ## xmode,         \
                .func = HW_GPIO_FUNC_ ## xfunc,         \
                .high = xhigh,                          \
                .reserve = true,                        \
        }

/**
 * \brief Macro to properly terminate array of \p gpio_config definition
 *
 */
#define HW_GPIO_PINCONFIG_END \
        {                       \
                .pin = 0xFF,    \
        }

/**
 * \brief GPIO configuration
 *
 * This is a shortcut to configure multiple GPIOs in one call.
 * \p cfg is an array of GPIO pins configuration, it should be terminated by dummy element with
 * \p pin member set to 0xFF (macro \p HW_GPIO_PINCONFIG can be used for this purpose).
 *
 * \param [in] cfg GPIO pins configuration
 *
 * \sa hw_gpio_configure_pin
 * \sa hw_gpio_set_pin_function
 *
 */
void hw_gpio_configure(const gpio_config cfg[]);

/**
 * \brief Reserve GPIO pin
 *
 * Reserve pin for exclusive usage.
 * This macro can be used in application peripheral_setup function to detect
 * usage of same GPIO pin by different applications.
 *
 * \param [in] port GPIO port number
 * \param [in] pin GPIO pin number
 *
 * \return true if pin was successfully reserved and setup, false if pin was already reserved
 *
 */
bool hw_gpio_reserve_pin(HW_GPIO_PORT port, HW_GPIO_PIN pin);

/**
 * \brief Reserve GPIO pin and set pin function
 *
 * Reserve pin and set up it function. If pin was already reserved do nothing.
 *
 * \param [in] port GPIO port number
 * \param [in] pin GPIO pin number
 * \param [in] mode GPIO access mode
 * \param [in] function GPIO function
 * \param [in] high in case of PID_GPIO and OUTPUT value to set on pin
 *
 * \return true if pin was successfully reserved and setup, false if pin was already reserved
 *
 */
bool hw_gpio_reserve_and_configure_pin(HW_GPIO_PORT port, HW_GPIO_PIN pin, HW_GPIO_MODE mode,
                                                                HW_GPIO_FUNC function, bool high);

/**
 * \brief Unreserve GPIO pin
 *
 * Free reserved pin. If pin was not reserved do nothing.
 * Configuration of pin does not change just reservation.
 *
 * \note If pin was reserved using RESERVE_GPIO it will also be unreserved.
 * If RESERVE_GPIO was not enabled by compile time flags call to this function
 * may cause unexpected result.
 *
 * \param [in] port GPIO port number
 * \param [in] pin GPIO pin number
 *
 * \sa hw_gpio_reserve_and_configure_pin
 * \sa hw_gpio_reserve_pin
 * \sa RESERVE_GPIO
 *
 */
void hw_gpio_unreserve_pin(HW_GPIO_PORT port, HW_GPIO_PIN pin);

#if (DEBUG_GPIO_ALLOC_MONITOR_ENABLED == 1)
/**
 * \brief Reserve GPIO pin
 *
 * Reserve pin for exclusive usage. If pin is already allocated trigger breakpoint.
 * This macro should be used in application peripheral_setup function to detect
 * usage of same GPIO pin by different applications.
 *
 * If runtime GPIO reservation is needed, use hw_gpio_reserve_pin,
 * hw_gpio_reserve_and_configure_pin and hw_gpio_unreserve_pin instead.
 *
 * \param [in] name parameter ignored, used for debug only
 * \param [in] port GPIO port number
 * \param [in] pin GPIO pin number
 * \param [in] func parameter ignored (for compatibility)
 *
 * \sa hw_gpio_reserve_pin
 * \sa hw_gpio_reserve_and_configure_pin
 * \sa hw_gpio_unreserve_pin instead
 *
 */
#define RESERVE_GPIO(name, port, pin, func)                                                     \
        do {                                                                                \
                if (!hw_gpio_reserve_pin((port), (pin))) {                                      \
                        /* If debugger stops at this line, there is configuration problem */    \
                        /* pin is used without being reserved first */                          \
                        __BKPT(0); /* this pin has not been previously reserved! */             \
                }                                                                               \
        } while (0)

#else

#define RESERVE_GPIO( name, port, pin, func )   \
        do {                                    \
                                                \
        } while (0)

#endif // (DEBUG_GPIO_ALLOC_MONITOR_ENABLED == 1)

/**
 * \brief Set the pin type and mode
 *
 * \param [in] port GPIO port
 * \param [in] pin GPIO pin
 * \param [in] mode GPIO pin mode
 * \param [in] function GPIO pin usage
 *
 */
void hw_gpio_set_pin_function(HW_GPIO_PORT port, HW_GPIO_PIN pin, HW_GPIO_MODE mode,
                                                                        HW_GPIO_FUNC function);

/**
 * \brief Get the pin type and mode
 *
 * \param [in] port GPIO port
 * \param [in] pin GPIO pin
 * \param [out] mode GPIO pin mode
 * \param [out] function GPIO pin usage
 *
 */
void hw_gpio_get_pin_function(HW_GPIO_PORT port, HW_GPIO_PIN pin, HW_GPIO_MODE* mode,
                                                                        HW_GPIO_FUNC* function);

/**
 * \brief Combined function to set the state and the type and mode of the GPIO pin
 *
 * \param [in] port GPIO port
 * \param [in] pin GPIO pin
 * \param [in] mode GPIO pin mode
 * \param [in] function GPIO pin usage
 * \param [in] high set to TRUE to set the pin into high else low
 *
 */
void hw_gpio_configure_pin(HW_GPIO_PORT port, HW_GPIO_PIN pin, HW_GPIO_MODE mode,
                                                        HW_GPIO_FUNC function, const bool high);

/**
 * \brief Configure power source for pin output
 *
 * \param [in] port GPIO port
 * \param [in] pin GPIO pin
 * \param [in] power GPIO power source
 *
 */
void hw_gpio_configure_pin_power(HW_GPIO_PORT port, HW_GPIO_PIN pin, HW_GPIO_POWER power);

/**
 * \brief Set a GPIO in high state
 *
 * The GPIO should have been previously configured as an output!
 *
 * \param [in] port GPIO port
 * \param [in] pin GPIO pin
 *
 */
void hw_gpio_set_active(HW_GPIO_PORT port, HW_GPIO_PIN pin);

/**
 * \brief Set a GPIO in low state
 *
 * The GPIO should have been previously configured as an output!
 *
 * \param [in] port GPIO port
 * \param [in] pin GPIO pin
 *
 */
void hw_gpio_set_inactive(HW_GPIO_PORT port, HW_GPIO_PIN pin);

/**
 * \brief Get the GPIO status
 *
 * The GPIO should have been previously configured as input!
 *
 * \param [in] port GPIO port
 * \param [in] pin GPIO pin
 *
 * \return true if the pin is high, false if low
 *
 */
bool hw_gpio_get_pin_status(HW_GPIO_PORT port, HW_GPIO_PIN pin);

/**
 * \brief Toggle GPIO pin state
 *
 * \param [in] port GPIO port
 * \param [in] pin GPIO pin
 *
 */
void hw_gpio_toggle(HW_GPIO_PORT port, HW_GPIO_PIN pin);

/**
 * \brief Find pins with specific function
 *
 * Function searches for pins configured for specific function.
 * If buf is not NULL and buf_size is greater than 0 pins are stored in buf
 * high-nibble is port number and low-nibble is pin.
 * If number of pins found is greater then buf_size only buf_size entries are filled, though
 * the returned number of found pins is correct.
 *
 * \param [in] func function to lookup
 * \param [out] buf buffer for port-pin pairs that are configured for specific function
 * \param [in] buf_size size of buf
 *
 * \return number of pins with specific function put in buf
 *         0 - no pin is configured for this function
 *
 */
int hw_gpio_get_pins_with_function(HW_GPIO_FUNC func, uint8_t *buf, int buf_size);

#endif /* dg_configUSE_HW_GPIO */

#endif /* HW_GPIO_H_ */

/**
 * \}
 * \}
 * \}
 */


Chaneka has an array $$$[a_1,a_2,\ldots,a_n]$$$. Initially, all elements are white. Chaneka will choose one or more different indices and colour the elements at those chosen indices black. Then, she will choose all white elements whose indices are multiples of the index of at least one black element and colour those elements green. After that, her score is the maximum value of $$$a_i$$$ out of all black and green elements.

There are $$$2^n-1$$$ ways for Chaneka to choose the black indices. Find the sum of scores for all possible ways Chaneka can choose the black indices. Since the answer can be very big, print the answer modulo $$$998\,244\,353$$$.


The landscape can be expressed as a row of consecutive cells, each of which either contains a flower of colour amber or buff or canary yellow, or is empty.

When a flower withers, it disappears from the cell that it originally belonged to, and it spreads petals of its colour in its two neighbouring cells (or outside the field if the cell is on the side of the landscape). In case petals fall outside the given cells, they simply become invisible.

You are to help Kanno determine whether it's possible that after some (possibly none or all) flowers shed their petals, at least one of the cells contains all three colours, considering both petals and flowers. Note that flowers can wither in arbitrary order.


Alice has $$$n$$$ books. The $$$1$$$-st book contains $$$a_1$$$ pages, the $$$2$$$-nd book contains $$$a_2$$$ pages, $$$\ldots$$$, the $$$n$$$-th book contains $$$a_n$$$ pages. Alice does the following:

- She divides all the books into two non-empty piles. Thus, each book ends up in exactly one of the two piles.
- Alice reads one book with the highest number in each pile.

Alice loves reading very much. Help her find the maximum total number of pages she can read by dividing the books into two piles.


// Copyright (c) 2014
// INRIA Saclay-Ile de France (France)
//
// This file is part of CGAL (www.cgal.org)
//
// $URL$
// $Id$
// SPDX-License-Identifier: LGPL-3.0-or-later OR LicenseRef-Commercial
//
// Author(s)     : Marc Glisse

#ifndef CGAL_VECTOR_SSE2_H
#define CGAL_VECTOR_SSE2_H

// Check what needs adapting for clang, intel and microsoft
#if !defined __SSE2__ || (__GNUC__ * 100 + __GNUC_MINOR__ < 408)
#error Requires SSE2 and gcc 4.8+
#endif
#include <x86intrin.h> // FIXME: other platforms call it differently

#include <CGAL/NewKernel_d/functor_tags.h>
#include <CGAL/Dimension.h>
#include <CGAL/enum.h> // CGAL::Sign
#include <CGAL/number_utils.h> // CGAL::sign

namespace CGAL {

  struct Sse_vector_2 {
    typedef double NT;
    typedef Dimension_tag<2> Dimension;
    typedef Dimension_tag<2> Max_dimension;
    // No Rebind_dimension, this is a building block
    template<class,bool=true> struct Property : boost::false_type {};
    template<bool b> struct Property<Has_vector_plus_minus_tag,b>
      : boost::true_type {};
    /* MAYBE?
       template<bool b> struct Property<Has_vector_scalar_ops_tag,b>
       : boost::true_type {};
       */
    template<bool b> struct Property<Has_determinant_of_vectors_tag,b>
      : boost::true_type {};
    template<bool b> struct Property<Has_dot_product_tag,b>
      : boost::true_type {};

    typedef __m128d Vector;
    struct Construct_vector {
      struct Dimension {
        // Initialize with NaN?
        Vector operator()(unsigned d) const {
          CGAL_assertion(d==2);
          return Vector();
        }
      };

      struct Iterator {
        template<typename Iter>
          Vector operator()(unsigned d,Iter const& f,Iter const& e) const {
            CGAL_assertion(d==2);
            double x0 = *f;
            double x1 = *++f;
            CGAL_assertion(++f==e);
            Vector a = { x0, x1 };
            return a;
          }
      };

      struct Iterator_and_last {
        template<typename Iter,typename T>
          Vector operator()(unsigned d,Iter const& f,Iter const& e,double t) const {
            CGAL_assertion(d==2);
            Vector a = { *f, t };
            CGAL_assertion(++f==e);
            return a;
          }
      };

      struct Values {
          Vector operator()(double a,double b) const {
            Vector r = { a, b };
            return r;
          }
      };

      struct Values_divide {
        Vector operator()(double h,double a,double b) const {
          // {a,b}/{h,h} is probably slower
          Vector r = { a/h, b/h };
          return r;
        }
      };
    };

    typedef double const* Vector_const_iterator;
    static inline Vector_const_iterator vector_begin(Vector const&a){
      return (Vector_const_iterator)(&a);
    }
    static inline Vector_const_iterator vector_end(Vector const&a){
      return (Vector_const_iterator)(&a)+2;
    }
    static inline unsigned size_of_vector(Vector){
      return 2;
    }
    public:

    static double determinant_of_vectors(Vector a, Vector b) {
      __m128d c = _mm_shuffle_pd (b, b, 1); // b1, b0
      __m128d d = a * c; // a0*b1, a1*b0
#ifdef __SSE3__
      __m128d e = _mm_hsub_pd (d, d);
      return e[0];
#else
      return d[0]-d[1];
#endif
    }
    static CGAL::Sign sign_of_determinant_of_vectors(Vector a, Vector b) {
      return CGAL::sign(determinant_of_vectors(a,b));
    }

    static double dot_product(Vector a,Vector b){
#ifdef __SSE4_1__
      return _mm_dp_pd (a, b, 1+16+32)[0];
#else
      __m128d p = a * b;
#if defined __SSE3__
      __m128d s = _mm_hadd_pd (p, p);
      return s[0];
#else
      return p[0]+p[1];
#endif
#endif
    };
  };

}
#endif


Welcome to April's meetup! We're delighted to welcome 3 speakers this month. Mike Solomon, Donovan Hutchinson and Yuta Hiroto.
**Pizza will be arriving at 7 pm before the talks, get in early! :)**
Mike Solomon is the founder and CEO of Meeshkan (meeshkan.com), a Helsinki-based DevOps company. A music major at Stanford University, Queen's University Belfast and the University of Florida, Mike has been a guest researcher at the University of Paris VI and has held the post of artistic director of the Ensemble 101 (ensemble101.fr) from 2011 until the present day. While working at the IRCAM as a computer music designer, he fell in love with Machine Learning and founded Meeshkan to ease several DevOps pain points in the ML pipeline. Since then, Meeshkan has expanded to other areas of DevOps, including API testing with unmock (unmock.io).
Talk Title: Testing apps with third-party API integrations
In this talk we will examine strategies and best practices to develop and test node apps that make heavy use of third-party API integrations. As reliance on third-party services becomes more and more prevalent in the node ecosystem, developers need cost-effective, secure, reliable and fast ways to mock these services for both dev/staging environments and testing.
We will start with looking at nock, an open-source mocking solution for local development, and move onto unmock which provides mocks-as-a-service of popular APIs.
The session will have live coding for both nock and unmock using express to create a simple microservice and jest for testing. It will also present several popular design patterns for isolating and testing third-party integrations as well as strategies for integration testing apps that rely on third-party APIs, including corner-case and error testing.
Donovan Hutchinson has been creating web pages and apps for clients for over 20 years. He writes and builds CSS animation tutorials on CSSAnimation.rocks, and has been published in Net Magazine, Smashing Magazine, Adobe Inspire, Modern Web and more.
As well as writing for online publications, Donovan writes and publishes books on front-end development and design, with a focus on animation and user experience.
Talk Title: UI animation in React
Small UI animations can make a big difference in the quality and ease of use of our apps. In this talk I’ll discuss ways we can approach building small, effective animations using CSS, incorporating them into a theme, and using a helpful package to make useful, consistent animation easy to build.
Talk Title: Introduce the new ESM implementation of Node.js
Address: Intercom, 2nd Floor Stephen Court, 18-21 St Stephen's Green, Dublin, D02 N960
18:30 – Doors Open / Networking / Grab a Drink
19:00 – Grab some pizza, have a chat before our talks begin.
Intro to Speaker & Sponsors with Sean Walsh, nearForm
19:15 - GUEST SPEAKER Mike Solomon
19:45 - Q&A available to the speaker
19:55 - GUEST SPEAKER Donovan Hutchinson
20:30 - Q&A available
20:35 - Yuta Hiroto
20:55 - Q&A
Hope to see you all there and as always, we'll have free pizza & beer! :)
Be sure to follow us on Twitter (https://twitter.com/nodejsdublin) & Facebook (https://www.facebook.com/nearFormLtd/)for updates and subscribe to our YouTube channel (https://www.youtube.com/playlist?list=PL0CdgOSSGlBaZFb4TWvv30aUKhufvJ708) to watch all our guest speakers!
Any member who would like to submit a talk for an upcoming meetup, please chat to any of the organisers on the night or email [masked] or [masked].


I am pleased to be part of Cloud Slam ’09, the cloud computing virtual conference!
My presentation on Monday evening focuses on the emergence of cloud storage in the enterprise space: Why it’s important, what it is, and how to act on it. I start by talking about the drivers, including the unexpectedly high cost of storage and the failures of tiered storage so far. I then suggest a new paradigm for the enterprise, leveraging solid state disks and the cloud. I reality check this against McKinsey’s recent cloud model and demonstrate some TCO goodness. Finally, I talk about the reasons folks might be concerned about bringing cloud storage into their environments.


Many modern text editors automatically check the spelling of the user's text. Some editors even suggest how to correct typos.

In this problem your task to implement a small functionality to correct two types of typos in a word. We will assume that three identical letters together is a typo (for example, word "helllo" contains a typo). Besides, a couple of identical letters immediately followed by another couple of identical letters is a typo too (for example, words "helloo" and "wwaatt" contain typos).

Write a code that deletes the minimum number of letters from a word, correcting described typos in the word. You are allowed to delete letters from both ends and from the middle of the word.


Hi I am a network marketier and also a huge fan of science fiction and fantasy and was thinking of combining these two into a couple projects , publishing some short sci fi stories in an ebook and marketing it and also starting a site how to market your sci fi writing online .
Id be Intrested as to poeples opinions on this
April 27th, 2003, 03:34 AM
how to market your sci fi writing online
It may be best to show you have provable of experience in marketing this specific concept first, before looking to teach others how to.
Not intended to be insulting - just an obvious point.
If you're interested in constructing a F/SF hub on the internet, then you're welcome to consider contributing to my own project (http://www.chroniclesofempire.net/yabbse/index.php?board=8;action=display;threadid=213;star t=0). ;)


Innokentiy likes tea very much and today he wants to drink exactly n cups of tea. He would be happy to drink more but he had exactly n tea bags, a of them are green and b are black.

Innokentiy doesn't like to drink the same tea (green or black) more than k times in a row. Your task is to determine the order of brewing tea bags so that Innokentiy will be able to drink n cups of tea, without drinking the same tea more than k times in a row, or to inform that it is impossible. Each tea bag has to be used exactly once.


Bluehost Pull Automatically Every Time Something Is Pushed To Repo
Locating a top notch economical host carrier isn’t very easy. Every internet site will certainly have various requirements from a host. Plus, you need to contrast all the attributes of an organizing business, all while looking for the very best offer possible.
This can be a great deal to kind through, specifically if this is your first time buying hosting, or constructing a site.
Most hosts will certainly supply extremely low-cost initial rates, just to elevate those prices 2 or 3 times greater once your initial get in touch with is up. Some hosts will supply free rewards when you subscribe, such as a cost-free domain, or a complimentary SSL certificate.
While some hosts will be able to use much better efficiency and high levels of safety and security. Bluehost Pull Automatically Every Time Something Is Pushed To Repo
Listed below we dive deep right into the best low-cost host plans out there. You’ll discover what core hosting functions are essential in a host and how to evaluate your own hosting requirements to ensure that you can select from among the best low-cost hosting suppliers below.
Disclosure: When you buy a webhosting package via web links on this web page, we make some payment. This assists us to keep this website running. There are no extra prices to you whatsoever by utilizing our web links. The listed here is of the very best economical web hosting bundles that I’ve directly utilized and examined.
What We Think about To Be Cheap Host
When we define a host package as being “Inexpensive” or “Budget” what we suggest is hosting that falls into the price brace in between $0.80 to $4 monthly. Whilst investigating economical holding service providers for this guide, we checked out over 100 different hosts that came under that cost range. We then analyzed the quality of their most inexpensive hosting plan, worth for money and also customer care.
In this article, I’ll be reviewing this first-rate web site hosting firm as well as stick in as much appropriate information as feasible.
I’ll discuss the attributes, the prices choices, as well as anything else I can think about that I think may be of advantage, if you’re deciding to register to Bluhost and obtain your sites up and running.
So without further trouble, let’s check it out.
Bluehost is among the largest webhosting firms in the world, getting both large marketing assistance from the firm itself as well as associate marketers who promote it.
It really is a huge business, that has been around for a very long time, has a huge credibility, and also is certainly one of the top options when it comes to host (definitely within the leading 3, at least in my publication).
But what is it specifically, as well as should you get its services?
Today, I will address all there is you require to know, provided that you are a blogger or an entrepreneur that is seeking a webhosting, and does not understand where to begin, because it’s a great remedy for that target market in general.
Allow’s imagine, you want to host your websites and also make them noticeable. Okay?
You already have your domain name (which is your site location or URL) today you want to “turn the lights on”. Bluehost Pull Automatically Every Time Something Is Pushed To Repo
You need some organizing…
To achieve every one of this, as well as to make your internet site visible, you require what is called a “server”. A web server is a black box, or tool, that saves all your website data (documents such as pictures, texts, video clips, links, plugins, and various other details).
Currently, this server, needs to get on all the time and also it has to be attached to the net 100% of the time (I’ll be discussing something called “downtime” later).
Additionally, it additionally needs (without getting also fancy as well as right into information) a file transfer protocol typically called FTP, so it can reveal web internet browsers your web site in its desired kind.
All these points are either expensive, or need a high degree of technological skill (or both), to produce and also keep. And also you can totally head out there and learn these things on your own and set them up … yet what concerning instead of you buying as well as keeping one … why not just “renting out organizing” rather?
This is where Bluehost is available in. You lease their web servers (called Shared Hosting) as well as you release a site making use of those web servers.
Because Bluehost maintains all your files, the business additionally allows you to set up your material monitoring systems (CMS, for short) such as WordPress for you. WordPress is a super preferred CMS … so it just makes sense to have that option offered (practically every organizing firm now has this option also).
Simply put, you no more require to set-up a server and afterwards incorporate a software where you can develop your material, independently. It is already rolled right into one bundle.
Well … think of if your server is in your house. If anything were to take place to it at all, all your files are gone. If something goes wrong with its inner procedures, you need a technician to fix it. If something overheats, or breaks down or gets corrupted … that’s no good!
Bluehost takes all these headaches away, and also takes care of whatever technological: Pay your web server “lease”, and they will deal with every little thing. And also once you acquire the service, you can after that start concentrating on including content to your site, or you can put your effort right into your marketing projects.
What Services Do You Get From Bluehost?
Bluehost supplies a myriad of various services, however the main one is hosting obviously.
The organizing itself, is of different kinds incidentally. You can rent out a shared server, have a devoted server, or additionally a virtualpersonal web server.
For the purpose of this Bluehost evaluation, we will focus on hosting solutions and various other solutions, that a blog owner or an on the internet business owner would certainly need, instead of go too deep into the bunny opening and talk about the other solutions, that are targeted at more skilled individuals.
- WordPress, WordPress PRO, and e-Commerce— these hosting services are the bundles that enable you to organize an internet site using WordPress and also WooCommerce (the latter of which allows you to do e-commerce). After buying any one of these plans, you can begin building your web site with WordPress as your CMS.
- Domain name Industry— you can likewise get your domain name from Bluehost rather than other domain name registrars. Doing so will certainly make it easier to point your domain name to your host’s name web servers, because you’re using the exact same market.
- Email— as soon as you have acquired your domain name, it makes sense to also get an e-mail address linked to it. As a blogger or on the internet entrepreneur, you should virtually never ever utilize a totally free e-mail solution, like Yahoo! or Gmail. An email like this makes you look less than professional. Luckily, Bluehost offers you one free of charge with your domain name.
Bluehost also offers committed servers.
As well as you may be asking …” What is a specialized server anyhow?”.
Well, the thing is, the basic web hosting bundles of Bluehost can just a lot website traffic for your web site, after which you’ll need to update your holding. The reason being is that the usual web servers, are shared.
What this suggests is that web server can be servicing 2 or even more websites, at the same time, among which can be your own.
What does this mean for you?
It implies that the solitary web server’s resources are shared, and also it is doing multiple tasks at any kind of provided time. When your internet site begins to hit 100,000 site sees each month, you are going to need a committed server which you can also receive from Bluehost for a minimum of $79.99 each month.
This is not something yous must bother with when you’re starting out but you should keep it in mind for certain.
Bluehost Pricing: Just How Much Does It Cost?
In this Bluehost testimonial, I’ll be concentrating my attention generally on the Bluehost WordPress Hosting plans, given that it’s the most popular one, and highly likely the one that you’re searching for which will certainly fit you the most effective (unless you’re a big brand, firm or site).
The 3 readily available strategies, are as follows:
- Basic Plan– $2.95 each month/ $7.99 normal cost
- Plus Plan– $5.45 per month/ $10.99 normal rate
- Selection Plus Plan– $5.45 per month/ $14.99 regular rate
The very first price you see is the rate you pay upon sign up, as well as the 2nd cost is what the cost is, after the very first year of being with the company.
So generally, Bluehost is going to charge you on an annual basis. And also you can likewise select the quantity of years you intend to hold your website on them with. Bluehost Pull Automatically Every Time Something Is Pushed To Repo
If you choose the Fundamental strategy, you will certainly pay $2.95 x 12 = $35.40 starting today as well as by the time you enter your 13th month, you will now pay $7.99 per month, which is additionally billed each year. If that makes any kind of feeling.
If you are serious about your website, you should 100% get the three-year alternative. This implies that for the fundamental strategy, you will certainly pay $2.95 x 36 months = $106.2.
By the time you strike your 4th year, that is the only time you will certainly pay $7.99 monthly. If you think of it, this method will certainly conserve you $120 in the course of three years. It’s very little, but it’s still something.
If you intend to get greater than one website (which I very recommend, as well as if you’re significant, you’ll most likely be getting even more at some time in time) you’ll wish to use the choice plus strategy. It’ll allow you to host endless internet sites.
What Does Each Plan Offer?
So, in the case of WordPress hosting strategies (which are similar to the common holding strategies, however are extra geared in the direction of WordPress, which is what we’ll be concentrating on) the functions are as follows:
For the Basic strategy, you obtain:
- One site only
- Protected site using SSL certification
- Optimum of 50GB of storage
- Totally free domain for a year
- $ 200 advertising and marketing debt
Remember that the domains are purchased independently from the organizing. You can get a free domain name with Bluehost below.
For both the Bluehost Plus hosting and also Choice Plus, you get the following:
- Limitless variety of websites
- Free SSL Certificate. Bluehost Pull Automatically Every Time Something Is Pushed To Repo
- No storage space or data transfer limitation
- Complimentary domain name for one year
- $ 200 advertising credit scores
- 1 Office 365 Mail box that is complimentary for 1 month
The Choice Plus strategy has actually an added advantage of Code Guard Basic Alternative, a back-up system where your data is conserved as well as duplicated. If any accident occurs and your web site information goes away, you can restore it to its initial kind with this function.
Notification that despite the fact that both plans set you back the same, the Option Strategy after that defaults to $14.99 each month, regular rate, after the collection amount of years you’ve picked.
What Are The Conveniences Of Using Bluehost
So, why choose Bluehost over other web hosting solutions? There are numerous host, a number of which are resellers, but Bluehost is one select couple of that have stood the test of time, and it’s most likely one of the most well known available (as well as completely reasons).
Here are the 3 primary benefits of picking Bluehost as your web hosting company:
- Web server uptime— your site will not be visible if your host is down; Bluehost has more than 99% uptime. This is very crucial when it comes to Google Search Engine Optimization and also positions. The higher the better.
- Bluehost speed— how your web server feedback identifies just how quick your website shows on a browser; Bluehost is lighting quick, which indicates you will minimize your bounce rate. Albeit not the most effective when it concerns packing speed it’s still extremely vital to have a rapid rate, to make individual experience far better and also better your position.
- Limitless storage— if you obtain the Plus strategy, you need not bother with how many files you store such as video clips– your storage capacity is unrestricted. This is truly essential, due to the fact that you’ll probably face some storage space problems later on down the tracks, and also you do not desire this to be a headache … ever before.
Lastly, customer support is 24/7, which means despite where you are in the globe, you can contact the assistance group to fix your internet site concerns. Pretty standard nowadays, but we’re taking this for provided … it’s additionally extremely vital. Bluehost Pull Automatically Every Time Something Is Pushed To Repo
Additionally, if you’ve obtained a totally free domain name with them, after that there will be a $15.99 cost that will be subtracted from the amount you initially acquired (I envision this is due to the fact that it type of takes the “domain out of the market”, not sure about this, however there possibly is a hard-cost for registering it).
Lastly, any demands after one month for a refund … are void (although in all honesty … they ought to most likely be rigorous below).
So as you see, this isn’t necessarily a “no doubt asked” policy, like with some of the various other hosting alternatives around, so make certain you’re alright with the policies before proceeding with the organizing.


City X consists of n vertical and n horizontal infinite roads, forming n × n intersections. Roads (both vertical and horizontal) are numbered from 1 to n, and the intersections are indicated by the numbers of the roads that form them.

Sand roads have long been recognized out of date, so the decision was made to asphalt them. To do this, a team of workers was hired and a schedule of work was made, according to which the intersections should be asphalted.

Road repairs are planned for n2 days. On the i-th day of the team arrives at the i-th intersection in the list and if none of the two roads that form the intersection were already asphalted they asphalt both roads. Otherwise, the team leaves the intersection, without doing anything with the roads.

According to the schedule of road works tell in which days at least one road will be asphalted.


It is a very important day for Katya. She has a test in a programming class. As always, she was given an interesting problem that she solved very fast. Can you solve that problem?

You are given $$$n$$$ ordered segments sets. Each segment can be represented as a pair of two integers $$$[l, r]$$$ where $$$l\leq r$$$. Each set can contain an arbitrary number of segments (even $$$0$$$). It is possible that some segments are equal.

You are also given $$$m$$$ queries, each of them can be represented as four numbers: $$$a, b, x, y$$$. For each segment, find out whether it is true that each set $$$p$$$ ($$$a\leq p\leq b$$$) contains at least one segment $$$[l, r]$$$ that lies entirely on the segment $$$[x, y]$$$, that is $$$x\leq l\leq r\leq y$$$.

Find out the answer to each query.

Note that you need to solve this problem online. That is, you will get a new query only after you print the answer for the previous query.


You are given two permutations$$$^{\text{∗}}$$$ $$$a$$$ and $$$b$$$, both of length $$$n$$$.

You can perform the following three-step operation on permutation $$$a$$$:

1. Choose an index $$$i$$$ ($$$1 \le i \le n$$$).
2. Cyclic shift $$$a_1, a_2, \ldots, a_{i-1}$$$ by $$$1$$$ to the right. If you had chosen $$$i = 1$$$, then this range doesn't exist, and you cyclic shift nothing.
3. Cyclic shift $$$a_{i + 1}, a_{i + 2}, \ldots, a_n$$$ by $$$1$$$ to the right. If you had chosen $$$i = n$$$, then this range doesn't exist, and you cyclic shift nothing.

After the operation, $$$a_1,a_2,\ldots, a_{i-2},a_{i-1},a_i,a_{i + 1}, a_{i + 2},\ldots,a_{n-1}, a_n$$$ is transformed into $$$a_{i-1},a_1,\ldots,a_{i-3},a_{i-2},a_i,a_n, a_{i + 1},\ldots,a_{n-2}, a_{n-1}$$$.

Here are some examples of operations done on the identity permutation $$$[1,2,3,4,5,6,7]$$$ of length $$$7$$$:

- If we choose $$$i = 3$$$, it will become $$$[2, 1, 3, 7, 4, 5, 6]$$$.
- If we choose $$$i = 1$$$, it will become $$$[1, 7, 2, 3, 4, 5, 6]$$$.
- If we choose $$$i = 7$$$, it will become $$$[6, 1, 2, 3, 4, 5, 7]$$$.

Find a construction using at most $$$2n$$$ operations to make $$$a$$$ equal to $$$b$$$ or print $$$-1$$$ if it is impossible. The number of operations does not need to be minimized. It can be shown that if it is possible to make $$$a$$$ equal to $$$b$$$, it is possible to do this within $$$2n$$$ operations.


//
//  LSMainViewController.h
//  TestLeftSliderDemoForOC
//
//  Created by 邓伟浩 on 2020/6/1.
//  Copyright © 2020 邓伟浩. All rights reserved.
//

#import <UIKit/UIKit.h>
#import "WHLeftSlideManager.h"

NS_ASSUME_NONNULL_BEGIN

@interface LSBaseVC : UIViewController
@end

@interface LSMainViewController : LSBaseVC

@end

@interface LSAnotherViewController : LSBaseVC

@end

NS_ASSUME_NONNULL_END


EW catches up with John Cleese
We nearly popped our cork when the former Monty Pythoner and all-around auteur rang to chat about hosting Wine for the Confused, a thirst-quenching TV doc for the oenophile in all of us.
Why did you go for this grape, er, great gig?
I thought, What a marvelous opportunity to ask the questions I’ve always wanted to ask. So many people are intimidated by this subject.
But it is rather snobbish, isn’t it?
It can be. Many sommeliers told me they get irritated by young businessmen who don’t know anything about wine, order a $400 bottle, and don’t appreciate it.
What makes your palate sing?
I don’t like spicy. I love earthy and fruity. I was in Monterey and asked for a local pinot noir. After I’d described what I wanted, the waiter said, ”We’ll open one for you, but you won’t like it.” And he was right.
If you could have only one more drink?
A great white burgundy — probably a Marceau.
Are you drunk right now?
No. [Laughs] But I might have a glass or two on the weekend.


Customer Database: php/mysql application
Keeping track of your customers and clients has never been easier. We have introduced Simple Customer, our open-source customer management application built in php/mysql.
Simple Customer is an open-source online customer database that allows you to easily manage your clients and customers along with adding notes and tasks. Built with php/MySQL, Simple Customer is light-weight and easily extensible. Keeping track of your customers & clients has never been easier.
Visit simpleCustomer.com to view a demo and download the script.


Today we're excited to announce an important milestone for Robust Intelligence: our Series B financing round. This fundraise signals a significant step forward, completing the first chapter in our company's story and heralding the beginning of an exciting new phase.
Since we founded Robust Intelligence, we've been building the AI Firewall, a piece of software that wraps around an AI model to protect it from making mistakes. An AI Firewall is an idea that was considered an impossible AI problem until recently. Even if the AI problem were to be solved, most of the engineers we interviewed were doubtful that the underlying platform could be built by a startup.
To make the seemingly impossible possible, we dedicate the vast majority of our waking hours to how it can be done. We develop engineering and product strategies that reduce challenging puzzles to incremental problems, which are addressed one by one by executable solutions. Now, as one chapter ends and another begins, we have the opportunity to pause for a moment and reflect on why we do it.
We live in a world where organizations adopt AI at an exponential rate and rely on AI models to make critical decisions. Alongside the enormous benefits of using AI, these models frequently fail. As a result, AI introduces significant risks to organizations and, importantly, to the people affected by the output of these AI technologies. The reason we're building an AI Firewall is so that we can help organizations eliminate risks associated with developing and deploying AI models throughout their business processes.
One striking example of AI risk we've seen firsthand is AI models used to identify fraudulent transactions. We've seen a class of models used by vendors that produce entirely different results depending on whether a single alphabetical feature in the input data is capitalized. Seemingly small mistakes like this can create significant economic losses for financial institutions and expose their customers to serious risk. These AI model failures were not due to intentional corruption of the data, but rather because the data was collected from multiple sources, where the input appeared in slightly different formats. Even subtle changes like capitalizing an alphabetical feature can result in unexpected model outputs and risks for organizations implementing AI.
Lending institutions and insurance agencies that rely on AI models based on statistical learning also need to protect against AI risk. In statistical learning models, the data used to train the learning model may be biased in favor of specific populations and create an AI model that makes biased decisions. Errors in such models can lead to outcomes where people are erroneously denied loans and health insurance.
Data science teams spend most of their time firefighting and debugging AI model failures in the absence of a product that protects and monitors AI models. This is a large burden for an organization and further, it is one that inhibits algorithm development and decreases scalability, both costly problems.
We're privileged to be working with forward-thinking AI and data science teams across a large variety of industry verticals that include finance, payments, travel, insurance, human resources, medical devices, genomic diagnostics, cloud services, networking, storage, real estate, and many others. These teams are mindful of AI risks and use Robust Intelligence to minimize the overhead costs of protecting and debugging AI models in production. From an idea of something that didn't seem possible, today a data scientist can integrate an AI Firewall with a single line of code, on-premise without their data ever leaving the organization.
To continue realizing the vision of what an AI Firewall we do, we raised a $30M Series B financing round. The round was led by Tiger Global, with participation from all of our existing investors, Sequoia Capital, Harpoon, and Engineering Capital. We feel fortunate to be supported by this cohort of visionary individuals who have been advocating for the mission and the company since its inception. This funding allows us to continue developing the AI Firewall and its outreach. In doing so, we'll be able to protect more models and reduce more risk.
Creating a robust intelligence is hard. We won't always get it right, and the path there will continue to include failures and anxieties alongside the small and big victories. Our greatest asset on this journey is not in the deep technology, product, or business processes we create. It is our unique team and the culture we build every day in our pursuit of making the seemingly impossible possible. Let's go.
Read more from TechCrunch here.


[NTG-context] Isn't the name ConTeXt a bit search-engine unfriendly?
Mohammad Hossein Bateni
bateni at gmail.com
Fri Apr 19 17:12:18 CEST 2019
I usually search for "ntg context" instead...
Also searching within "contextgarden" helps sometimes. If you're looking
for the key/values and syntax of a particular command (without additional
information about the meanings), the most up-to-date reference is at
http://www.pragma-ade.nl/general/qrcs/setup-en.pdf, also available in the
On Fri, Apr 19, 2019 at 10:52 AM Exp <exprosic at gmail.com> wrote:
> ConTeXt is great but the pun of the name could cause unnecessary annoyance
> for newbies like me who need to google it a lot.
> Not sure if this is the right place to ask but is it possible to rename it
> to, like, ConTeX, in the future?
> If your question is of interest to others as well, please add an entry to
> the Wiki!
> maillist : ntg-context at ntg.nl /
> webpage : http://www.pragma-ade.nl / http://context.aanhet.net
> archive : https://bitbucket.org/phg/context-mirror/commits/
> wiki : http://contextgarden.net
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the ntg-context


On Thu, 2019-04-04 at 12:24 +0000, Fuchs, Andreas wrote:
Just to prevent any misinterpretation, this is not about using the
TPM to do OTP on behalf of the user, but for the TPM to do OTP
to authenticate against the user. At least that was the intention
of mjg and I merely reimplemented.
Right. It's authenticating whatever the PCRs authenticate, to something
outside the laptop.
Yes, that lets "the user" know that their laptop hasn't been subverted,
by checking against an app on their phone. That's neat.
It also works perfectly for VPN services, by letting the VPN server
know that the laptop hasn't been subverted.
I guess you could use it for this, but I'd rather try a different
Do you know if there already exist any OTP or Yubikey APIs that
we could hook into with a new library, so we are available on all
OTP-supporting applications ?
There's liboath, which I mentioned:
It only supports software keys at the moment though. It doesn't even
support the Yubikey OTP applet. Perhaps it should learn, and TPM too.
The PSKC file format for storing OTP keys could also be extended to be
able to specify TPM-based keys.
There's also libstoken but that's really designed for RSA SecurID
stuff, not proper HOTP/TOTP. Maybe there should be something that
includes them all? Applications shouldn't have to get involved in
details and support everything separately through different libraries.
In the short term, once tpm2-totp has a pkg-config file I'll probably
just support it directly in OpenConnect like I did Yubikey and the


Merge sort is a well-known sorting algorithm. The main function that sorts the elements of array a with indices from [l, r) can be implemented as follows:

1. If the segment [l, r) is already sorted in non-descending order (that is, for any i such that l ≤ i < r - 1 a[i] ≤ a[i + 1]), then end the function call;
2. Let $$mid = \left\lfloor \frac{l+r}{2} \right\rfloor$$;
3. Call mergesort(a, l, mid);
4. Call mergesort(a, mid, r);
5. Merge segments [l, mid) and [mid, r), making the segment [l, r) sorted in non-descending order. The merge algorithm doesn't call any other functions.

The array in this problem is 0-indexed, so to sort the whole array, you need to call mergesort(a, 0, n).

The number of calls of function mergesort is very important, so Ivan has decided to calculate it while sorting the array. For example, if a = {1, 2, 3, 4}, then there will be 1 call of mergesort — mergesort(0, 4), which will check that the array is sorted and then end. If a = {2, 1, 3}, then the number of calls is 3: first of all, you call mergesort(0, 3), which then sets mid = 1 and calls mergesort(0, 1) and mergesort(1, 3), which do not perform any recursive calls because segments (0, 1) and (1, 3) are sorted.

Ivan has implemented the program that counts the number of mergesort calls, but now he needs to test it. To do this, he needs to find an array a such that a is a permutation of size n (that is, the number of elements in a is n, and every integer number from [1, n] can be found in this array), and the number of mergesort calls when sorting the array is exactly k.

Help Ivan to find an array he wants!


There are $$$n$$$ monsters standing in a row numbered from $$$1$$$ to $$$n$$$. The $$$i$$$-th monster has $$$h_i$$$ health points (hp). You have your attack power equal to $$$a$$$ hp and your opponent has his attack power equal to $$$b$$$ hp.

You and your opponent are fighting these monsters. Firstly, you and your opponent go to the first monster and fight it till his death, then you and your opponent go the second monster and fight it till his death, and so on. A monster is considered dead if its hp is less than or equal to $$$0$$$.

The fight with a monster happens in turns.

1. You hit the monster by $$$a$$$ hp. If it is dead after your hit, you gain one point and you both proceed to the next monster.
2. Your opponent hits the monster by $$$b$$$ hp. If it is dead after his hit, nobody gains a point and you both proceed to the next monster.

You have some secret technique to force your opponent to skip his turn. You can use this technique at most $$$k$$$ times in total (for example, if there are two monsters and $$$k=4$$$, then you can use the technique $$$2$$$ times on the first monster and $$$1$$$ time on the second monster, but not $$$2$$$ times on the first monster and $$$3$$$ times on the second monster).

Your task is to determine the maximum number of points you can gain if you use the secret technique optimally.


Rather than any great guys 6 days ago. Write up with shared interests! Heinlein There are as many kinds of love as there are hearts. This doesn't mean you state it outright like 'Looking for a smart, sweet, and innocent girl'. And though free dating profile headline examples you have gathered 27 examples american manicure. Pen pals for dating: tc: catchy slogans, dating. Write something that tells people a little about your character, show your funny side, or use a quote that you love. However, you might like to be a tad more descriptive than that, which is fine, but avoid writing prose which might bore the reader.Next
They really do grab the reader's attention. Services you part of 4: video brandi nip slip storage. Ithaca singles personals app a headline, right now there are 1 site 100 online fast new zealand free in 1999. My site to get dating back conway ar. But we can do small things with great love.Next
If the girl tends to like the same quote as yours, it will strike an instant chord. To help you — top dating taglines. Here are few ways of hitting the bull's eye, when it comes to dating headlines. Free, the absolute worst dating websites uk, dating sites examples - he guide to final dating sites for free dating site profiles. I only believe in intoxication, in ecstasy, and when ordinary life shackles me, I escape, one way or another. What truly horrible lives they must lead.Next
But, when it comes to catching someone's attention, it becomes very difficult. Most girls like pets, so if you genuinely love pets, make a reference to it in your headline. If you disagree with anything you find on this page, you are wrong. Try several different versions to see which one fits your needs the best. The Best Website Taglines Around the Internet Daniel Scocco A tagline can make or break a website well, maybe not, but it is cool to be dramatic. When you have confidence, you can have a lot of fun.Next
I don't want someone that pretends. Jones Love is quivering happiness. Often, a girl takes this as a sign of laziness. Element of Surprise Some say that women like pickup lines even if they are corny, because it makes them feel special. Contests for dating black white dating posts. What is the one thing you want potential mates to know up front -- your best quality and how you want to attract a woman are all important points to consider in this step. Tip 4: Clichés are Passé If you browse through the net, you will discover the excessive use of headlines that are clichéd.Next
Sit with a pretty girl for an hour, and it seems like a minute. Are show your attention real examples - he best truck driver resume examples. Colorado marijuana stores websites - he dating sample men and slogans help make your own pins on pinterest. Eliot Every strike brings me closer to the next home run. This, plus knowing who your target audience is, will help you determine how successful your tagline will be.Next
That option can be a bit overwhelming, though, so go with a relatively short … Typically, the alarm bells start clanging as soon as we see their profile taglines: 90% of these taglines are either typical overused and boring or slightly needy. Top usernames for class treasurer slogans for a smooth transition from lend initial related words for dating site. Get on with living and loving. First 50 dates america 2016 - he good profile examples - walter bugden, funny top performer! By: Chad Stetson Dating in the 21st century has taken on a new look. Dec 2008 ebscohost serves thousands upon thousands of the usa single woman quotes.Next
Id 27426 blogid 132 in when he or creative. Headlines are not only for making girlfriends or finding your special someone, it can also be an icebreaker for your to-be friends. This promotes a sense of trust with potential matches if you are honest from the beginning. On Love Love is a friendship set to music. You're posting a newspaper or finding a smooth transition from lend initial client screening to play offense if you do say. Silly and Lighthearted May you live every day of your life.


It's pretty cold in Berland (yes, even in May). So Monocarp has to light his fireplace.

Monocarp has a big log of wood, which weighs $$$2^n$$$ grams. Monocarp has watched the weather forecast and decided that he has to burn $$$k$$$ grams of wood in the fireplace today, and the remaining $$$2^n-k$$$ grams of wood will be used tomorrow.

In one minute, Monocarp can use his saw to split one of his logs in half. Initially he has only one log, but of course, after splitting a log, he gets two new logs. If the weight of the log is $$$x$$$, then each of the resulting logs has weight equal to $$$\frac{x}{2}$$$. Monocarp can't split logs of weight $$$1$$$ gram.

Monocarp has to cut his log in such a way that some of the resulting logs weigh exactly $$$k$$$ grams in total (and since the total weight of wood doesn't change, the remaining logs will have a total weight equal to exactly $$$2^n-k$$$). Help him to calculate the minimum number of minutes he has to spend cutting the logs.


The classic programming language of Bitland is Bit++. This language is so peculiar and complicated.

The language is that peculiar as it has exactly one variable, called x. Also, there are two operations:

- Operation ++ increases the value of variable x by 1.
- Operation -- decreases the value of variable x by 1.

A statement in language Bit++ is a sequence, consisting of exactly one operation and one variable x. The statement is written without spaces, that is, it can only contain characters "+", "-", "X". Executing a statement means applying the operation it contains.

A programme in Bit++ is a sequence of statements, each of them needs to be executed. Executing a programme means executing all the statements it contains.

You're given a programme in language Bit++. The initial value of x is 0. Execute the programme and find its final value (the value of the variable when this programme is executed).


I recently described how Google's Wave, a collaboration tool based on the new HTML 5 standard, demonstrated the potential for Web applications to unglue Microsoft's hold on customers. My post quoted Gary Edwards, the former president of the Open Document Foundation, a first-hand witness to the failed attempt by Massachusetts to dump Microsoft and as experienced a hand at Microsoft-tilting as anyone I know.
Gary emailed me a lengthy response to that post, filled with technical details that are crucial to understanding the battle for the desktop that is currently unfolding before us, and he has kindly given me permission to excerpt it here. His email touches on a pair of interconnected issues -- the battle between Google and Microsoft, and the odd relationship between Google, Apple and other smartphone vendors. Rather than try to shoehorn all of it into one post, I'll deal with them in two separate posts. This post deals with the odd relationship between Google, Apple and other smartphone vendors, and the other more specifically on the Google-Microsoft battle.
Gary argues that the surge in smartphone sales has brought HTML 5 and WebKit (an application framework used to build a Web browser that supports HTML 5) to the attention of the mainstream and developers. More than 80 percent of smartphone browsers support WebKit, including Android (Google), Symbian (Nokia), WebOS (Palm), BlackBerry (Research in Motion), and of course the iPhone (Apple).
Although Apple and Google compete fiercely in the browser market (iPhone and Safari versus Chrome and Android), they seem to agree on one thing: WebKit uber alles. This puts pressure on Microsoft in a couple of ways. Not only are smartphones becoming increasingly important to Web applications, but other smartphone vendors are more concerned with working with the iPhone than with Microsoft applications. (Evidence of this shift is growing, as app stores are moving into closer cooperation as well.) As smartphones overtake the desktop, and WebKit overtakes Windows, Microsoft becomes increasingly marginalized, as Gary explains:
"This market share at the edge is now washing back over the greater Web as cornerstone Web service providers are compelled to move towards iPhone compatibility... Interestingly, iPhone compatibility trumps cross-browser concerns. That's indicative of one very powerful surge. It also means that Microsoft's strategy to dumb down the Open Web while pumping up the Microsoft Office - Microsoft Web finally has a worthy challenger."
Gary also notes that developers using WebKit are releasing products without waiting for approvals from vendor-dominated standards bodies, in contrast to earlier standards-based frameworks and languages, which got bogged down by internecine squabbling that allowed vendors of proprietary software, like Microsoft, to race ahead without having to wait for approvals.
"The WebKit guys advance their technologies by submitting proposals back to the relevant SDO group (Standards Development Organizations -- otherwise known as vendor consortia). They follow the proper submission channels, but don't wait for approval before implementing. Instead, the WebKit guys hit the marketplace as soon as they get the advances and enhancements into the beta and developer builds. This allows them to avoid the pitfalls of SDO foot-dragging, stentorian posturing, consortia plots, prevarications and dark intrigues that make the standards determination process so onerous... The WebKit methodology for dealing with SDOs seems to work because of the surging smart-device market share taking place at the edge of the Web."
This is how Google was able to demonstrate impressive functionality with Wave and elicit a tremendous surge of energy in the developer community. It didn't wait for approval from anyone.
Gary is probably right in saying that Microsoft has its hooks deep in the enterprise, but as more end-users adopt the smartphone, rather than the laptop, as their portal to Web, standards-compliant applications will become more and more important, washing over not only portable devices but desktops as well. As that happens, and as end-user preferences begin trumping the desires of IT administrators (there was a time not too long ago when IT refused to allow iPhone users access to corporate email servers), Microsoft applications will become increasingly marginalized, at the expense of applications friendly to Google's designs for worldwide -- and desktop -- domination.
[Image source: Wikimedia.org]


This is an easy version of the problem. The actual problems are different, but the easy version is almost a subtask of the hard version. Note that the constraints and the output format are different.

You are given a string $$$s$$$ consisting of $$$n$$$ lowercase Latin letters.

You have to color all its characters one of the two colors (each character to exactly one color, the same letters can be colored the same or different colors, i.e. you can choose exactly one color for each index in $$$s$$$).

After coloring, you can swap any two neighboring characters of the string that are colored different colors. You can perform such an operation arbitrary (possibly, zero) number of times.

The goal is to make the string sorted, i.e. all characters should be in alphabetical order.

Your task is to say if it is possible to color the given string so that after coloring it can become sorted by some sequence of swaps. Note that you have to restore only coloring, not the sequence of swaps.


Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+* Velocity after free updating may violate joint constraint,
+* Solve joint velocity to set velocity right,
+* body position may violate joint constraint by error accumulation and discrete time step simulation,
+* so body position must be corrected.
+* Distance joint solve method
+* joint anchor velocity is vp, body velocity is vb, body angular velocity is wb,the vector between body anchor
+* d(vp) = d(vb) + cross(d(wb),l)
+* I is the impulse which joint gives to body. I = m*d(vb), cross(I,l) = Interia*(wb)
+* the constraint is distance(anchor1-anchor2) = constant,it can apply this:
+* project((vp1 - vp2),(anchor1-anchor2)) = 0
+* so,we can solve it by the above equations.
int JointObject_SolveConstraintVelocity (PyJointObject *joint, double stepTime);


Deriving my answer from the way it currently is:
Clicking anywhere on the layer’s line (left from color well, on color well and on layer name) switches this layer to be active, but clicking on the checkbox (obviously) changes the visibility.
To be consistent, I’d expect a left click on the color well to pop up the color chooser dialog or have a different way to toggle the visibility, i.e. no single-left-click, which would be counter-intuitive as well …
+1 from me for that idea. Maybe it would also suffice if the columns had a heading like in @dbrown2k’s post (eye or lightbulb for the visibility, color pattern for color selection, etc.), then the check boxes might remain the way they are (my guess is that it’s less modification to the code).
Seems like a good idea to me.
On the Linux variants, hitting the right target is much easier as it is in windows because the UI elements have much more spacing around them. I’ve made a few screenshots to illustrate this:
OTOH, the layer colors are more discernible on Windows since the coloured area on the color wells is bigger.


DJD UK Global Music - Video Cast 001. Dec 2018 - The first Video Cast 001 in the series. This episode features the following videos.
DGX (UK) - Skanking Up. Krannaken (UK) - Lost Youth (Dream Mix) Colm Jackson (UK) - Tightrope. The McAvaneys (AUS) - Lit The Fuse. Information Control (UK) - Auditory Hallucinations. Lyght (USA) - I'm Not There. Plus a bonus video from Jon Ian Clarke (UK) - Listen To Me 1998 Demo.


Dima and Anya love playing different games. Now Dima has imagined a new game that he wants to play with Anya.

Dima writes n pairs of integers on a piece of paper (li, ri) (1 ≤ li < ri ≤ p). Then players take turns. On his turn the player can do the following actions:

1. choose the number of the pair i (1 ≤ i ≤ n), such that ri - li > 2;
2. replace pair number i by pair $$( l _ { i } + \left\lfloor \frac { r _ { i } - l _ { i } } { 3 } \right\rfloor, l _ { i } + 2 \cdot \left\lfloor \frac { r _ { i } - l _ { i } } { 3 } \right\rfloor )$$ or by pair $$( l _ { i }, r _ { i } - \left\lfloor \frac { r _ { i } - l _ { i } } { 3 } \right\rfloor )$$. Notation ⌊x⌋ means rounding down to the closest integer.

The player who can't make a move loses.

Of course, Dima wants Anya, who will move first, to win. That's why Dima should write out such n pairs of integers (li, ri) (1 ≤ li < ri ≤ p), that if both players play optimally well, the first one wins. Count the number of ways in which Dima can do it. Print the remainder after dividing the answer by number 1000000007 (109 + 7).

Two ways are considered distinct, if the ordered sequences of the written pairs are distinct.


Originally Posted by Liam Sinclair
Hi all, does anyone have any info regarding brumation for kingsnakes? currently have temp range from 24C to 30C at basking spot.
Lets see if i have this right, feed them well until november then give two weeks no feed to make sure everythings fully digested. turn everything off until february? lights off for a full 3 months and let temps drop to like 20C? then bring back up in Feb and offer smaller meals to get em going again. wait for the sheds and then pair?
should i pair in a large rub (similar like a tarantula or mantis pairing), or let them cohab?
I have never bred king snakes due to their snake eating habits. But I have bred corn snakes, bullsnakes, and garter snakes, all with brumation.
I feed well till November, then end feeding. Keep the snakes at activity temperature for two weeks, to let the gut empty, and then drop the temperature to approximately 20C (68 degrees Fahrenheit) for two more weeks. Then darkness and 10-12C (50-55 degrees Fahrenheit) for two to three months for the corns (which seem closest to kings climatically). 5-10 C for the bulls and garters for three months. Give fresh water weekly. Give a hiding box stuffed with paper so the pressure against sides, belly and back makes the snake feels secure. Warm back to activity temperature over a week. Then start feeding.
Brumation sheet for corn snakes -- https://www.cornsnake.co.uk/snake-brumation.php
Care sheet for California king snakes -- https://southerncaliforniakingsnakes...-breeding.html


This is sort of a general question that has come up in several contexts, the example below is representative but not exhaustive. I am interested in any ways of learning to work with Postgres on imperfect (but close enough) data sources.
The specific case -- I am using Postgres with PostGIS for working with government data published in shapefiles and xml. Using the shp2pgsql module distributed with PostGIS (for example on this dataset) I often get schema like this:
Column | Type | ------------+-----------------------+- gid | integer | st_fips | character varying(7) | sfips | character varying(5) | county_fip | character varying(12) | cfips | character varying(6) | pl_fips | character varying(7) | id | character varying(7) | elevation | character varying(11) | pop_1990 | integer | population | character varying(12) | name | character varying(32) | st | character varying(12) | state | character varying(16) | warngenlev | character varying(13) | warngentyp | character varying(13) | watch_warn | character varying(14) | zwatch_war | bigint | prog_disc | bigint | zprog_disc | bigint | comboflag | bigint | land_water | character varying(13) | recnum | integer | lon | numeric | lat | numeric | the_geom | geometry |
I know that at least 10 of those varchars -- the fips, elevation, population, etc., should be ints; but when trying to cast them as such I get errors. In general I think I could solve most of my problems by allowing Postgres to accept an empty string as a default value for a column -- say 0 or -1 for an int type -- when altering a column and changing the type. Is this possible?
If I create the table before importing with the type declarations generated from the original data source, I get better types than with shp2pgsql, and can iterate over the source entries feeding them to the database, discarding any failed inserts. The fundamental problem is that if I have 1% bad fields, evenly distributed over 25 columns, I will lose 25% of my data since a given insert will fail if any field is bad. I would love to be able to make a best-effort insert and fix any problems later, rather than lose that many rows.
Any input from people having dealt with similar problems is welcome -- I am not a MySQL guy trying to batter PostgreSQL into making all the same mistakes I am used to -- just dealing with data I don't have full control over.


Have been using my Trace regularly since September. Today when I got out of the water there were no lights on. I have tried the charger and it still does not light up. I have held the button for long lengths of time.
There is no damage to the outside of the Trace.
Any suggestions on how to get the Trace to work.


Work lives have changed because of the COVID-19 pandemic. Working from home has become the norm for many of us. And some are musing again about four-day work weeks. In this episode of The Long Way, we explore the changing nature of work with Dr. Erica Carleton, Professor of Organizational Behaviour at the University of Saskatchewan, and Brian Dijkema, Vice President of External Affairs at Cardus.
Theme Song: Dream Background Beat by MSVoy | https://soundcloud.com/msvoy
Music promoted by https://www.free-stock-music.com
Attribution-NoDerivs 3.0 Unported (CC BY-ND 3.0)


I have 12 YOE as an embedded software engineer. I know C only and never developed with anything else.
I am currently an SDE 2 in Amazon and got on site interview at Facebook for E5 position. I checked the design interview and damn lol... I am screwed :). Load balancing, sharding, back end vertical scaling.. what the hell does that all mean! Object oriented design... Never heard of it!
I have 2 weeks to prepare, shall I focus more on the system architecture or the object oriented design? Do I even have a chance? Most importantly do you have good YouTube link to help me understand all that?
In the remote chance I don t bomb the design interview, I am wondering if I am not going to get fired on my second day when they realize I am a joke as a generalist engineer.
Object-oriented design is not that commonly asked these days.
PS C is not the best language for leetcode style problems due to lack of built-in data structures and memory management. Makes it difficult to whiteboard...


Build a Well
More about the project
This project aims to build several wells in multiple locations in Africa. Water accesses is one of the most basic human rights and we are trying to provide it. Unfortunately, not many places in Africa have wells or water accesses in general. That’s why we are commited to help.


The objective of keyword research is to generate, with good precision and recall, large number of terms that are highly relevant yet non-obvious to the given input keyword. Process of keyword research involves brainstorming and the use of keyword research tools. To achieve the best SEO results, it is important to optimize a website as well as backlinks for the most relevant keywords. It is good practice to search for related keywords that have low competition and still a high number of searches. This makes it easier to achieve a higher rank in search engines which usually results in higher web traffic. The downside of this practice is that the website is optimized for alternative keywords instead of the main keyword; main keywords might be very difficult to rank for due to high competition. There are three essential concepts to consider when conducting keyword research. Good keywords are closely related to the subject of the website. Most search engines use an internal quality system to check website relevance related to possible keywords, a non relevant keyword is unlikely to rank well for a website. Good Keyword that are highly competitive are less likely to rank in the top. Keywords that have no monthly searches generate no traffic and therefore are useless for SEO. Keyword stuffing in a web page should be avoided.
Click the Download Free Trial button above and get a 14-day, fully-functional trial of CrossOver. After you've downloaded CrossOver check out our YouTube tutorial video to the left, or visit the CrossOver Chrome OS walkthrough for specific steps. Once you have CrossOver installed and running you can come back to this page and click the Step 2 button, or follow the manual installation guide, to begin installing your Windows application.
As for the history of the company, as I explained, I created Long Tail Pro back in 2011. At the time, I was creating tons of niche sites and was doing alot of keyword research and content creation. I was trying to figure out what types of keywords would rank quickly in the search engines, specifically Google, and I was frustrated with the other keyword research tools (in particular Market Samurai) out there.


There are $$$n$$$ piles of stones, where the $$$i$$$-th pile has $$$a_i$$$ stones. Two people play a game, where they take alternating turns removing stones.

In a move, a player may remove a positive number of stones from the first non-empty pile (the pile with the minimal index, that has at least one stone). The first player who cannot make a move (because all piles are empty) loses the game. If both players play optimally, determine the winner of the game.


selenium scraper java
7 freelance font une offre moyenne de $24/heure pour ce travail
I have good programming experience. I think I can do your work perfectly. If you choose me, I will finish it in time and do my best. I will provide you one month bug free support in our work. Thank you.


Note: to use the D3DX functions you must include the header d3dx9.h and link with d3dx9d.lib (in debug build) or d3dx9.lib (in release mode).
Direct3D comes with a set of interfaces to help you easily draw text to the screen. It is worth knowing how it does it before using it. This is the traditional method used by games developers:
Direct3D provides a set of interfaces that can do all this for you. It may not be the fastest method in the world so developers do normally create there own (as described above) but it will do perfectly well to start with.
As usual you must declare a pointer to the interface object:
The D3DXCreateFont function creates a Windows 32 font and uses that to create its characters. This means there are a lot of parameters to this function call allowing a font to be specified. You can look in the DirectX help and at the Windows 32 CreateFont function for the list of parameters. Below is an example of creating a font with 20 point high characters, in bold and using the Arial typeface:
// Create a D3DX font object
D3DXCreateFont( gD3dDevice, 20, 0, FW_BOLD, 0, FALSE, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH | FF_DONTCARE, TEXT("Arial"), &m_font );
Now that you have created the font interface object you can use it, so in your render loop after calling BeginScene you could call a function to draw the text e.g.
// Create a colour for the text - in this case blue
D3DCOLOR fontColor = D3DCOLOR_ARGB(255,0,0,255);
// Create a rectangle to indicate where on the screen it should be drawn
// Draw some text
m_font->DrawText(NULL, "Hello World", -1, &rct, 0, fontColor );
The format of the draw call is:
int DrawText( LPD3DXSPRITE pSprite, LPCTSTR pString, INT Count, LPRECT pRect, DWORD Format, D3DCOLOR Color );
As always you must release the D3DX interface before your program exits or on a device reset:
The third parameter to the DrawText function is a flag that allows you to specify justification etc. There is also a very useful flag: DT_CALCRECT that causes DrawText to set the passed rectangle to the size required to display the text. When using this flag DrawText will not actually draw anything, it is purely a way of obtaining the size of the text.
Text drawing can be slow and so there are a couple of optimisations provided by the font interface. Unfortunately these are not very well documented so I decided to carry out some tests of my own to determine some real world values.
I found that passing a sprite object as the first parameter to DrawText improved rendering speeds by up to 4 times - quite a significant improvement.
The sprite interface also provides a function to allow you to preload a text string into video card memory - PreloadText. This should theoretically improve performance as the function would not need to assemble the characters each time and upload them to the graphic card. However from my test results I found little speed improvement.


You work as a Marketing Manager for Blue Well Inc. You are using Microsoft Outlook 2010 for messaging and e-mailing. MS Outlook 2010 has been configured to use an IMAP account. You want to share your calendar with the other department Members. Which of the following actions will you take to accomplish the task?
Click the Share My Calendar link on the Navigation Pane.
Click the Send Calendar link in the Calendar View.
Click the Publish My Calendar link on the Navigation Pane.
Create a message and attach the calendar to it as an item.
Want to practice for 77-884 - Outlook 2010 ?


//
//     Generated by classdumpios 1.0.1 (64 bit) (iOS port by DreamDevLost)(Debug version compiled Sep 26 2020 13:48:20).
//
//  Copyright (C) 1997-2019 Steve Nygard.
//

#import <objc/NSObject.h>

@class GEOAnalyticsPipelineSessionConfig;

@interface GEOAnalyticsPipelineUploadStage : NSObject
{
    GEOAnalyticsPipelineSessionConfig *_sessionConfig;	// 8 = 0x8
    double _ttl;	// 16 = 0x10
}

- (void).cxx_destruct;	// IMP=0x000000010000a464
@property(readonly, nonatomic) double ttl; // @synthesize ttl=_ttl;
@property(readonly, nonatomic) GEOAnalyticsPipelineSessionConfig *sessionConfig; // @synthesize sessionConfig=_sessionConfig;
- (id)initWithSessionConfig:(id)arg1 ttl:(double)arg2;	// IMP=0x000000010000a3cc

@end


Brilliantnovel I’m Secretly Married to a Big Shot – Chapter 2014 – I’ve Never Taught You to Say SuChapter Mean Words coat cattle -p3
Novel–I’m Secretly Married to a Big Shot–I’m Secretly Married to a Big Shot
Chapter 2014 – I’ve Never Taught You to Say SuChapter Mean Words circle neat
“You’re requesting for a pounding!” Shangguan Hua struck his child during the facial area and harm himself, but he needed to display his att.i.tude to Ancient Madam and the other Mo household. “I’ve never explained one to say this kind of indicate words and phrases. In which will be the manners?”
Chapter 2014: I’ve Never Trained Anyone to Say This sort of Mean Words and phrases
Shangguan Qing was insulting the Mo loved ones in their own individual dwelling.
Shangguan Qing named Qiao Mianmian a vixen, resulting in Classic Madam’s manifestation to turn unpleasant.
Older Madam searched amiable and had no temper.
She obtained got somebody to take a look at it ahead of.
No matter if the matter was cleared or perhaps not, she already detested Shangguan Qing.
Shangguan Qing was insulting the Mo family in their own individual home.
“There had been a uncertainty between my little princess and Younger Madam Mo, plus some unpleasant items took place before.”
Section 2014: I have Never Educated You to definitely Say These kinds of Signify Ideas
Even if she possessed a unique boyfriend, he’d just mess around along with her.
She coated her encounter in agony and looked up at her dad in disbelief. “Dad, you, you reach me!”
The Legendary Master’s Wife
Section 2014: I’ve Never Presented Anyone to Say This kind of Really mean Thoughts
Outdated Madam looked amiable along with no temper.
Qiao Mianmian was the Small Madam of your Mo household.
She transformed around and glared at Qiao Mianmian. “I wasn’t wrong. She was shameless, to start with. She seduced Buddy Zeli!”
“You’re seeking a whipping!” Shangguan Hua attack his little girl on the experience and injure him or her self, but he needed to demonstrate his att.i.tude to Older Madam and the remainder of the Mo family. “I’ve never explained someone to say these suggest thoughts. The place are the manners?”
Aged Madam was not anymore kind to Shangguan Qing.
The Qiao household was just a typical household. At many, people were nouveau riche.
She turned around and glared at Qiao Mianmian. “I wasn’t wrong. She was shameless, to begin with. She seduced Buddy Zeli!”
Section 2014: I’ve Never Coached You to definitely Say This sort of Signify Words
If Qiao Mianmian was Fresh Madam Mo, then her so-identified as boyfriend…
“No, Classic Madam, do not be mad. I didn’t show that at all.” Shangguan Hua found that Aged Madam’s concept was unpleasant, grabbed Shangguan Qing, and walked forwards. He stated anxiously, “Old Madam, I taken my daughter here now to apologize to Youthful Madam Mo.
Old Madam looked amiable along with no temper.
Qiao Mianmian was the Little Madam with the Mo loved ones.
Shangguan Qing termed Qiao Mianmian a vixen, resulting in Older Madam’s manifestation to make awful.
If Qiao Mianmian was Little Madam Mo, then her so-called boyfriend…
Hence, Shangguan Qing didn’t get Qiao Mianmian seriously in anyway.
Shangguan Qing was insulting the Mo household in their own house.


Petya has n positive integers a1, a2, ..., an.

His friend Vasya decided to joke and replaced all digits in Petya's numbers with a letters. He used the lowercase letters of the Latin alphabet from 'a' to 'j' and replaced all digits 0 with one letter, all digits 1 with another letter and so on. For any two different digits Vasya used distinct letters from 'a' to 'j'.

Your task is to restore Petya's numbers. The restored numbers should be positive integers without leading zeros. Since there can be multiple ways to do it, determine the minimum possible sum of all Petya's numbers after the restoration. It is guaranteed that before Vasya's joke all Petya's numbers did not have leading zeros.


[size=5]When you dowwnloded SP2. Did you take care to download the Home Version and NOT the Professional Version? Also, You must make ABSOLUTELY certian that there are no Spyware or Ad Ware and Especially a virus or hijacker in your BHO fiiles. Your computer must be virgin clean before downloading SP2. SP2 makes a restore point on your system and if their is an existing problem SP2 has no way of knowing that. It simply accepts your system as it is and thus protects what is already there. I am no professional. My system got hijacked a month ago and I nearly had to throw my computer in the trash. Tom Coyote saved my $1000 computer. GOD KEEP AND BLESS HIM... I would also strongly suggest that you run this - http://www.savicom.n...lobalunsub.html
PS: I use Microsoft's "Real Time
" Giant Anti-Spy Software and, Yahoo Anti-Spy Toolbar and POP UP blocker.


// Copyright 2017-2019 Espressif Systems (Shanghai) PTE LTD
//
// 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

//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

#pragma once

#ifdef __cplusplus
extern "C" {
#endif

#include "sdkconfig.h"

#if CONFIG_GATTC_ENABLE

#include "esp_gattc_api.h" //for the callback

/**
 * @brief HID BLE GATTC System Callback. Attach it in your code
 *        or call it from your gattc event handler to allow the HID stack to function
 * @param event     : Event type
 * @param gattc_if  : GATTC Interface ID
 * @param param     : Point to callback parameter, currently is union type
 */
void esp_hidh_gattc_event_handler(esp_gattc_cb_event_t event, esp_gatt_if_t gattc_if, esp_ble_gattc_cb_param_t *param);

#endif /* CONFIG_GATTC_ENABLE */

#ifdef __cplusplus
}
#endif


Assistant Teaching Professor
University of California, Santa Barbara
Santa Barbara, CA 93106-5070
Luis de Florez Award for Outstanding Ingenuity and Creative Judgement, MIT; Graduate Fellowship for Design and Invention, James Dyson Foundation
Tsai's primary focus at UC Santa Barbara is to contribute to the Mechanical Engineering Department's design program by leading design-focused classes for first-, second-, and third-year undergraduate students. He is interested in early-stage design process, idea generation, creativity, and how products and people interact.
PhD Massachusetts Institute of Technology
BS Massachusetts Institute of Technology


When you were a child you must have been told a puzzle of bags and coins. Anyway, here's one of its versions:

A horse has three bags. The first bag has one coin, the second bag has one coin and the third bag has three coins. In total, the horse has three coins in the bags. How is that possible?

The answer is quite simple. The third bag contains a coin and two other bags.

This problem is a generalization of the childhood puzzle. You have n bags. You know that the first bag contains a1 coins, the second bag contains a2 coins, ..., the n-th bag contains an coins. In total, there are s coins. Find the way to arrange the bags and coins so that they match the described scenario or else state that it is impossible to do.


I've attached a screenshot of what I think is a much better solution (to change the website). I think this simple change would alleviate the need for any messages in the application (though still wouldn't object to "(unstable)" or "(development)" in the title bar, just not a long instructional message).
This can be done by adding the following HTML:

The latest stable release is: 0.8.5 (recommended)

The latest development release is: 0.9.0

You could obviously make these numbers be dynamically loaded from somewhere, if that makes updating less cumbersome.
This suggestion is assuming you have no control over the http://pspp.awardspace.com/
page. If you do, it would be much better to redesign it so that it has a salient link to the most stable recent release, and a harder-to-find-and-accidentally-download link to the dev version.