blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 3 264 | content_id stringlengths 40 40 | detected_licenses listlengths 0 85 | license_type stringclasses 2
values | repo_name stringlengths 5 140 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringclasses 905
values | visit_date timestamp[us]date 2015-08-09 11:21:18 2023-09-06 10:45:07 | revision_date timestamp[us]date 1997-09-14 05:04:47 2023-09-17 19:19:19 | committer_date timestamp[us]date 1997-09-14 05:04:47 2023-09-06 06:22:19 | github_id int64 3.89k 681M ⌀ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 22
values | gha_event_created_at timestamp[us]date 2012-06-07 00:51:45 2023-09-14 21:58:39 ⌀ | gha_created_at timestamp[us]date 2008-03-27 23:40:48 2023-08-21 23:17:38 ⌀ | gha_language stringclasses 141
values | src_encoding stringclasses 34
values | language stringclasses 1
value | is_vendor bool 1
class | is_generated bool 2
classes | length_bytes int64 3 10.4M | extension stringclasses 115
values | content stringlengths 3 10.4M | authors listlengths 1 1 | author_id stringlengths 0 158 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
be89ea4c5bd78e8d9ee4f6c72dda4908684f6722 | 5f99d28a6807340158ebff89b4cafafd252b9d74 | /XMLLib/xml.hpp | f48b1ab43deb058de34c5ab013443551b1038c8b | [] | no_license | NotAPenguin0/XMLLib | 5ebd533dc3d66c3e0a06d735520fd09fd86cc0d1 | 7ab71d26cb8f87ed8e9a4a0525aa90e908728ab1 | refs/heads/master | 2020-04-20T17:03:13.469038 | 2019-02-03T18:22:29 | 2019-02-03T18:22:29 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 6,908 | hpp | #ifndef MVG_XML_HPP_
#define MVG_XML_HPP_
#include "charconv.hpp"
#include "tree.hpp"
#include <sstream>
#include <string>
#include <unordered_map>
#include <variant>
#include <vector>
namespace mvg::xml {
struct xml_version {
int major;
int minor;
};
namespace detail {
template<typename T, typename U, typename... Us>
struct is_one_of {
static constexpr bool value =
std::is_same<std::remove_cv_t<T>, std::remove_cv_t<U>>::value ||
is_one_of<T, Us...>::value;
};
template<typename T, typename U>
struct is_one_of<T, U> {
static constexpr bool value =
std::is_same<std::remove_cv_t<T>, std::remove_cv_t<U>>::value;
};
} // namespace detail
#define XML_TPL_DECL \
template<typename Num, typename Unsigned, typename Bool, typename Float, \
typename String>
#define XML_BASIC_TPL_ARG_LIST <int, unsigned int, bool, float, std::wstring>
#define XML_BASIC_TPL_ARG_LIST_NO_BRACKETS \
int, unsigned int, bool, float, std::wstring
#define XML_TPL_ARG_LIST <Num, Unsigned, Bool, Float, String>
#define XML_TPL_ARG_LIST_NO_BRACKETS Num, Unsigned, Bool, Float, String
XML_TPL_DECL
class xml_element {
public:
// This should not be an unordered_map, since the keys are not guaranteed to
// be unique
using nested_elem_t = std::unordered_map<String, xml_element>;
xml_element() = default;
template<typename T>
xml_element(String const& tag,
T&& data,
std::unordered_map<String, String> attributes) :
tag_(tag),
data_(std::forward<T>(data)), attributes_(attributes) {
static_assert(
detail::is_one_of<T, XML_TPL_ARG_LIST_NO_BRACKETS, nested_elem_t>,
"Type T must be a valid xml type");
}
xml_element(xml_element const&) = default;
xml_element(xml_element&&) = default;
xml_element& operator=(xml_element const&) = default;
xml_element& operator=(xml_element&&) = default;
void set_tag(String const& t) { tag_ = t; }
String tag() const { return tag_; }
template<typename T>
void set_data(T&& t) {
data_ = t;
}
Num as_number() const { return std::get<Num>(data_); }
Unsigned as_unsigned() const { return std::get<Unsigned>(data_); }
Float as_float() const { return std::get<Float>(data_); }
Bool as_bool() const { return std::get<Bool>(data_); }
String as_string() const { return std::get<String>(data_); }
auto& operator[](String const& nested_tag) {
if (!std::holds_alternative<nested_elem_t>(data_)) {
throw std::bad_variant_access();
}
return std::get<nested_elem_t>(data_).at(nested_tag);
}
private:
String tag_;
std::variant<XML_TPL_ARG_LIST_NO_BRACKETS, nested_elem_t> data_;
std::unordered_map<String, std::variant XML_TPL_ARG_LIST> attributes_;
};
XML_TPL_DECL
class basic_xml {
public:
using number_t = Num;
using unsigned_t = Unsigned;
using bool_t = Bool;
using float_t = Float;
using string_t = String;
using istringstream_t = std::basic_istringstream<
typename string_t::value_type,
std::char_traits<typename string_t::value_type>>;
basic_xml() = default;
basic_xml(basic_xml const&) = default;
basic_xml(basic_xml&&) = default;
basic_xml& operator=(basic_xml const&) = default;
basic_xml& operator=(basic_xml&&) = default;
static basic_xml parse(string_t const& xml) {
istringstream_t sstream(xml);
// The resulting xml
basic_xml parsed;
// Every valid xml document must start with a 'prolog'
parse_prolog(sstream, parsed);
return parsed;
}
xml_version version() { return version_; }
private:
static void parse_prolog(istringstream_t& sstream, basic_xml& result) {
// Example of a prolog:
/*
<?xml version="1.1"?>
*/
// See the XML standard at:
// https://www.w3.org/TR/2006/REC-xml11-20060816/#sec-prolog-dtd
std::wstring buf;
sstream >> buf;
// Check if the first word of the XMl document is ' <?xml '. If not,
// this is not a well-formed prolog
if (buf != L"<?xml") {
throw syntax_error(
"Syntax error: Prolog: Expected XML declaration");
}
// Read the next part of the XML declaration. This should be '
// version="x.y" '
sstream >> buf;
result.version_ = parse_version(buf);
}
static xml_version parse_version(std::wstring& buf) {
// First, remove spaces in this part, because they will be annoying for
// parsing
buf.erase(std::remove(buf.begin(), buf.end(), L' '), buf.end());
static constexpr std::size_t version_decl_size =
9; // == strlen("version=\"");
if (buf.substr(0, version_decl_size) != L"version=\"") {
throw syntax_error(
"Syntax error: Prolog: Expected version declaration");
}
try {
// Find the version separator '.'
std::size_t sep = buf.find_first_of('.');
if (sep == std::wstring::npos) {
throw syntax_error("Syntax error: Prolog: Expected symbol '.'");
}
// sep - version_decl_size is the length of the version number. The
// version number starts after the version declaration, so at index
// version_decl_size
auto version_major = std::stoi(
buf.substr(version_decl_size, sep - version_decl_size));
// Get the second part of the version, following the same pattern
std::size_t end_quote = buf.find_last_of(buf, L'\"');
auto version_minor =
std::stoi(buf.substr(sep + 1, end_quote - sep));
return {version_major, version_minor};
} catch (std::out_of_range const& e) {
throw parse_error("Could not parse version number: '" +
charconv::string_convert<std::string>(
buf.substr(version_decl_size)) +
"'. Version number too large");
} catch (std::invalid_argument const& e) {
throw syntax_error("Could not parse version number: '" +
charconv::string_convert<std::string>(
buf.substr(version_decl_size)) +
"'. Not a number.");
}
}
tree<xml_element XML_TPL_ARG_LIST> tree_;
xml_version version_;
};
using xml = basic_xml XML_BASIC_TPL_ARG_LIST;
#undef XML_TPL_ARG_LIST
#undef XML_TPL_ARG_LIST_NO_BRACKETS
#undef XML_BASIC_TPL_ARG_LIST
#undef XML_BASIC_TPL_ARG_LIST_NO_BRACKETS
#undef XML_TPL_DECL
} // namespace mvg::xml
#endif
| [
"33437@vitaetpax.be"
] | 33437@vitaetpax.be |
99053ab594555f5596f31da554477969239cb8b9 | 95afd2274905493f6dac880ddb0ecca44e1ca0d5 | /bitbots_splines_extension/src/visualisation/visual_splines_material.cpp | 450bd467da74aecb016acb0a13c39c3f8f35bf03 | [
"BSD-3-Clause"
] | permissive | 5reichar/bitbots_kick_engine | 483040fddd8e4a58bd92e386128ecab640de23d8 | 0817f4f0a206de6f0f01a0cedfe201f62e677a11 | refs/heads/master | 2021-06-22T19:20:44.246234 | 2021-01-04T14:32:21 | 2021-01-04T14:32:21 | 175,184,353 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 5,791 | cpp | #include <assert.h>
#include "visualisation/visual_splines_material.h"
namespace bitbots_splines{
VisualSplinesMaterial::VisualSplinesMaterial(std::shared_ptr<PoseHandle> & pose_handle)
: sp_curve_(pose_handle),
d_curve_scale_x_(1.0),
d_curve_scale_y_(1.0),
d_curve_scale_z_(1.0),
d_curve_scale_roll_(1.0),
d_curve_scale_pitch_(1.0),
d_curve_scale_yaw_(1.0),
m_e_curve_color(Color::white),
m_str_curve_namespace("Curve"),
m_uint_id(0)
{
}
/*
* Curve Attributes
*/
void VisualSplinesMaterial::set_scale(double curve_scale)
{
set_scale(curve_scale, curve_scale, curve_scale, curve_scale, curve_scale, curve_scale);
}
void VisualSplinesMaterial::set_scale(double curve_x, double curve_y, double curve_z, double curve_roll, double curve_pitch, double curve_yaw)
{
d_curve_scale_x_ = curve_x;
d_curve_scale_y_ = curve_y;
d_curve_scale_z_ = curve_z;
d_curve_scale_roll_ = curve_roll;
d_curve_scale_pitch_ = curve_pitch;
d_curve_scale_yaw_ = curve_yaw;
}
double VisualSplinesMaterial::get_scale_x() const
{
return d_curve_scale_x_;
}
double VisualSplinesMaterial::get_scale_y() const
{
return d_curve_scale_y_;
}
double VisualSplinesMaterial::get_scale_z() const
{
return d_curve_scale_z_;
}
double VisualSplinesMaterial::get_scale_roll() const{
return d_curve_scale_roll_;
}
double VisualSplinesMaterial::get_scale_pitch() const{
return d_curve_scale_pitch_;
}
double VisualSplinesMaterial::get_scale_yaw() const{
return d_curve_scale_yaw_;
}
void VisualSplinesMaterial::set_color(Color curve_color)
{
m_e_curve_color = curve_color;
}
Color VisualSplinesMaterial::get_color() const
{
return m_e_curve_color;
}
void VisualSplinesMaterial::set_namspace(std::string curve_namespace)
{
m_str_curve_namespace = curve_namespace;
}
std::string VisualSplinesMaterial::get_namspace() const
{
return m_str_curve_namespace;
}
void VisualSplinesMaterial::set_id(uint32_t curve_id)
{
m_uint_id = curve_id;
}
uint32_t VisualSplinesMaterial::get_id() const
{
return m_uint_id;
}
/*
* Point handeling
*/
void VisualSplinesMaterial::add_point_to_x(double const time, double const position, double const velocity, double const acceleration)
{
add_point(sp_curve_->x(), time, position, velocity, acceleration);
}
void VisualSplinesMaterial::add_point_to_y(double const time, double const position, double const velocity, double const acceleration)
{
add_point(sp_curve_->y(), time, position, velocity, acceleration);
}
void VisualSplinesMaterial::add_point_to_z(double const time, double const position, double const velocity, double const acceleration)
{
add_point(sp_curve_->z(), time, position, velocity, acceleration);
}
void VisualSplinesMaterial::add_point_to_roll(double const time, double const position, double const velocity, double const acceleration)
{
add_point(sp_curve_->roll(), time, position, velocity, acceleration);
}
void VisualSplinesMaterial::add_point_to_pitch(double const time, double const position, double const velocity, double const acceleration)
{
add_point(sp_curve_->pitch(), time, position, velocity, acceleration);
}
void VisualSplinesMaterial::add_point_to_yaw(double const time, double const position, double const velocity, double const acceleration)
{
add_point(sp_curve_->yaw(), time, position, velocity, acceleration);
}
void VisualSplinesMaterial::add_point(std::shared_ptr<Curve> curve, double const time, double const position, double const velocity, double const acceleration)
{
assert(curve);
curve->add_point(time, position, velocity, acceleration);
}
std::vector<std::vector<Curve::Point>> VisualSplinesMaterial::get_points() const
{
std::vector<std::vector<Curve::Point>> points;
points.push_back(sp_curve_->x()->points());
points.push_back(sp_curve_->y()->points());
points.push_back(sp_curve_->z()->points());
points.push_back(sp_curve_->roll()->points());
points.push_back(sp_curve_->pitch()->points());
points.push_back(sp_curve_->yaw()->points());
return points;
}
uint32_t VisualSplinesMaterial::get_number_of_points() const
{
return sp_curve_->x()->points().size();
}
/*
* Position handeling
*/
double VisualSplinesMaterial::get_position_from_x(double const time)
{
return sp_curve_->x() == nullptr ? 0.0 : sp_curve_->x()->position(time);
}
double VisualSplinesMaterial::get_position_from_y(double const time)
{
return sp_curve_->y() == nullptr ? 0.0 : sp_curve_->y()->position(time);
}
double VisualSplinesMaterial::get_position_from_z(double const time)
{
return sp_curve_->z() == nullptr ? 0.0 : sp_curve_->z()->position(time);
}
double VisualSplinesMaterial::get_position_from_roll(const double time)
{
return sp_curve_->roll() == nullptr ? 0.0 : sp_curve_->roll()->position(time);
}
double VisualSplinesMaterial::get_position_from_pitch(double const time)
{
return sp_curve_->pitch() == nullptr ? 0.0 : sp_curve_->pitch()->position(time);
}
double VisualSplinesMaterial::get_position_from_yaw(double const time)
{
return sp_curve_->yaw() == nullptr ? 0.0 : sp_curve_->yaw()->position(time);
}
} | [
"5reichar@informatik.uni-hamburg.de"
] | 5reichar@informatik.uni-hamburg.de |
eed634baa1a098f9c4ce12e7eb18ce4f77228d10 | ebceff05439fdefda4ba83880131bd299b4be8c2 | /SmartWatch_Software/Declarations.h | c9651657584ae0a269a4d91f26b4c3a17faf5453 | [
"MIT"
] | permissive | gynsolomon/ESP32-Smart-Watch | 7be464222b8b0e5e68d5a453e1ed61cbe42c0181 | 30b09c41cc169f85af7ce6d98a36e0d081bc41ac | refs/heads/master | 2022-12-08T10:15:01.662180 | 2020-08-19T03:12:30 | 2020-08-19T03:12:30 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 179,158 | h | #include <WiFi.h>
#include <Wire.h>
#include <Adafruit_GFX.h> // Core graphics library
#include <Adafruit_ST7735.h> // Hardware-specific library for ST7735
#include <SPI.h>
// #include "BluetoothSerial.h"
#include "BLEDevice.h"
//prints debug information to the serial terminal when declared
//#define DEBUG
//#define printDebug(a) Serial.println(a)
#ifndef DEBUG
#define printDebug(a)
#endif
#define SHOW_LAST_NOTIFICATION_TIME //when declared shows the time of the last recieved notification update at the bottom of the screen
//just to avoid putting my wifi credentials on the public repo
//Later the wifi credentials should be stored in eeprom or on the android device
#include "J:\Dropbox\Dropbox\Lab Projects\Smart Watch\WifiCredentials.h" //desktop computer location
//#include "C:\Users\James\Dropbox\Lab Projects\Smart Watch\WifiCredentials.h" //laptop computer location
#include "Pages.h"
#include "Icons.h"
//IconButtons.h is included below since it relies on some declarations
//color picker here http://www.barth-dev.de/online/rgb565-color-picker/
//look and feel and colors
#define BACKGROUND_COLOR ST77XX_BLACK
#define TEXT_COLOR ST77XX_WHITE
#define INTERFACE_COLOR ST77XX_WHITE
#define GRAYED 0xBDF7
int ERROR_COLOR = ST77XX_BLUE;
#define screenOnTime 15000 //time before watch screen times out without user input
//variables used globally
boolean deviceActive = false; //indicates that the device is being actively used (showing home and other UI elements with screen active)
boolean nonCriticalOperation = false; //indicates that the code running may take some time and can be interrupted if needed
boolean touchDetected = false;
int currentPage = HOME;
unsigned long lastTouchTime = 0;
//touch screen driver interrupt request
#define TOUCH_IRQ 4
//LCD pins
#define LCD_EN 13
#define LCD_CS 16
#define LCD_LED 14
#define LCD_SCK 18
#define LCD_DC 21 //LCD_A0
#define LCD_RST 22
#define LCD_MOSI 23
Adafruit_ST7735 tft = Adafruit_ST7735(LCD_CS, LCD_DC, LCD_RST);
//power regulation/monitoring pins
//#define BAT_ALRT 34 //not used in v4.1
#define CHG_STAT 35
#define REG_PG 36
//I2C Pins and Addresses
#define I2C_SCL 32
#define I2C_SDA 33
#define BAT_MONITOR_ADDR 0x36
#define TOUCH_ADDR 0x48
//Battery Monitor Configuration Values
//#define designcap 1200 //600mAh (0.5mAh resolution / 600mAh) (for 10m sense resistor)
#define designcap 480 //240mAh (240mAh /0.5mAh resolution ) (for 10m sense resistor)
#define ichgterm 20
#define vempty 0x9650
#define modelcfg 0x8400
//Bluetooth.ino
String sendBLE(String command, bool hasReturnData);
void initBLE();
void xFindDevice(void * pvParameters ) ;
void formConnection(void * pvParameters) ;
//Touch Calibration
#define X_MAX 233
#define X_MIN 19
#define Y_MAX 230
#define Y_MIN 14
//screen resolution (don't need any magic numbers)
#define SCREEN_WIDTH 160
#define SCREEN_HEIGHT 128
//frame buffer for drawing more elaborate UI elements
GFXcanvas16 *frameBuffer = new GFXcanvas16 (SCREEN_WIDTH, SCREEN_HEIGHT);
//Accelerometer connections (optional extra)
#define Z_ACCEL 25
#define X_ACCEL 26
#define Y_ACCEL 27
//Time tracker variables (Stored in RTC)
#define NOTIFICATION_DATA_BUFFER_SIZE 2048
RTC_DATA_ATTR char notificationData[NOTIFICATION_DATA_BUFFER_SIZE];
RTC_DATA_ATTR time_t now;
RTC_DATA_ATTR uint64_t Mics = 0;
RTC_DATA_ATTR struct tm *timeinfo;
#define SONG_NAME_BUFFER_SIZE 64
RTC_DATA_ATTR bool isPlaying = false;
RTC_DATA_ATTR char songName[SONG_NAME_BUFFER_SIZE];
const char *ntpServer = "pool.ntp.org";
const long gmtOffset_sec = -5 * 3600;
const int daylightOffset_sec = 0;
//structures
typedef struct onscreenButton button;
typedef struct iconButton iconButton;
//FREERTOS THINGS
TaskHandle_t xConnect = NULL;
TaskHandle_t xSong = NULL;
struct onscreenButton
{
int _x, _y, _width, _height, _color, _backgroundColor;
String _text;
};
struct iconButton
{
int _x, _y, _width, _height, _color, _backgroundColor;
uint16_t icon[16]; //16x16 icon (single color)
};
struct point
{
int xPos;
int yPos;
};
#include "IconButtons.h"
//window object
class Window
{
iconButton WindowUpArrowButton = {128, 0, 32, 48, INTERFACE_COLOR, BACKGROUND_COLOR, {(0b00000001 << 8) | 0b10000000, (0b00000011 << 8) | 0b11000000, (0b00000111 << 8) | 0b11100000, (0b00001111 << 8) | 0b11110000, (0b00011111 << 8) | 0b11111000, (0b00111111 << 8) | 0b11111100, (0b01111111 << 8) | 0b11111110, (0b11111111 << 8) | 0b11111111, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000}};
iconButton WindowDownArrowButton = {128, 48, 32, 48, INTERFACE_COLOR, BACKGROUND_COLOR, {(0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b11111111 << 8) | 0b11111111, (0b01111111 << 8) | 0b11111110, (0b00111111 << 8) | 0b11111100, (0b00011111 << 8) | 0b11111000, (0b00001111 << 8) | 0b11110000, (0b00000111 << 8) | 0b11100000, (0b00000011 << 8) | 0b11000000, (0b00000001 << 8) | 0b10000000}};
boolean _scroll;
String textBuffer = "";
boolean focused = true;
int scrollPosition = 0;
int _x, _y, _width, _height, x_cursor, y_cursor;
public:
Window(int x, int y, int width, int height, boolean scroll);
Window();
void print(String Text);
void println(String Text);
void touch();
void focus();
boolean isFocused();
private:
String getValue(String data, char separator, int index);
void drawTextToWindow(boolean clr);
};
/* a simple menu to allow a user to select from a list of choices, returns an integer for the selected value */
class SelectionWindow {
int selection;
int sectionWidth;
boolean focused = false;
int _x, _y, _width, _height;
int totalOptions = 1;
String options = "Cancel";
iconButton UpArrowButton = { 128, 0, 16, 48, INTERFACE_COLOR, BACKGROUND_COLOR, {(0b00000001 << 8) | 0b10000000, (0b00000011 << 8) | 0b11000000, (0b00000111 << 8) | 0b11100000, (0b00001111 << 8) | 0b11110000, (0b00011111 << 8) | 0b11111000, (0b00111111 << 8) | 0b11111100, (0b01111111 << 8) | 0b11111110, (0b11111111 << 8) | 0b11111111, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000}};
iconButton DownArrowButton = { 128, 0, 32, 48, INTERFACE_COLOR, BACKGROUND_COLOR, {(0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b00001111 << 8) | 0b11110000, (0b11111111 << 8) | 0b11111111, (0b01111111 << 8) | 0b11111110, (0b00111111 << 8) | 0b11111100, (0b00011111 << 8) | 0b11111000, (0b00001111 << 8) | 0b11110000, (0b00000111 << 8) | 0b11100000, (0b00000011 << 8) | 0b11000000, (0b00000001 << 8) | 0b10000000} };
button okButton = {128, 0, 32, 48, INTERFACE_COLOR, BACKGROUND_COLOR, "Ok"};
public:
SelectionWindow(int x, int y, int width, int height); //constructor determines form/size
int addOption(String s); //adds option and returns option number
int focus(); //focuses the window, will return integer representitive of the selected option
private:
void drawOptionsWindow(); //draws the option's string to the screen
String getValue(String data, char separator, int index); //splits the options string
void touch(); //touch handler
};
/***********************************************
* *
Function Signitures
* *
***********************************************/
//Battery_Monitor.ino
void initBatMonitor();
float getBatteryCurrent();
float getBatteryVoltage();
float getTotalCapacity();
float getRemainingCapacity();
int getBatteryPercentage();
void WriteAndVerifyRegister(char RegisterAddress, int RegisterValueToWrite);
int readRegister(byte deviceAddr, byte location);
void sendWrite(byte deviceAddr, byte location, int d);
float getTimeUntilEmpty();
//Display.ino
void initLCD();
//Touch.h
struct point readTouch();
void printPoint(struct point p);
void IRAM_ATTR TOUCH_ISR();
void initTouch();
void handleTouch();
//MainLoop.ino
void testScreen();
void MainLoop();
//TimeTracker.ino
void printLocalTime();
void updateTime(uint64_t elapsedTime);
void updateTimeFromNotificationData();
String getInternetTime();
//Home.ino
void drawHome();
void HomeTouchHandler(int x, int y);
void homeLoop();
void writeNotifications();
//notifications.ino
int getNotificationLines();
String parseFromNotifications(int line, int field);
String getValue(String data, char separator, int index);
void drawNotifications();
void NotificationsTouchHandler(struct point p);
void notificationsLoop();
void openNotification(int sel);
//animations.ino
void SweepClear();
//Button.ino
int TextWidth(button b);
void paintButton(button b);
void paintButton(iconButton b);
void paintButtonFull(button b);
void paintButtonFull(iconButton b);
void pressButton(iconButton b);
void pressButton(button b);
bool checkButtonPress(iconButton b, int x, int y);
bool checkButtonPress(button b, int x, int y);
bool checkButtonPress(button b);
bool checkButtonPress(iconButton b);
//Settings.ino
void about();
void testWifi();
void changeNetwork();
void batterySettings();
void reAdjustTime();
void accelTest();
void SettingsTouchHandler(struct point p);
void drawSettings();
void settingsLoop();
//CircularAnimation.ino
void drawArc(int x, int y, int outerRadius, int thickness, int thetaStart, int arcLength, int color);
void drawCircularAnimation1(int x, int y) ;
//apps.ino
void openApps();
//"pine.png" width=160 height=128
const uint16_t background [] PROGMEM = {0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0081, 0x00A1, 0x00C1, 0x0102, 0x0122, 0x0102, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x00A1, 0x0061, 0x0060, 0x00A1, 0x0102, 0x00A1, 0x0080, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0040, 0x0020, 0x0020, 0x0020, 0x0080, 0x00A0, 0x00A0, 0x00A1, 0x00C1, 0x00C1, 0x0122, 0x0142, 0x0142, 0x0162, 0x0183, 0x0183, 0x0163, 0x0163, 0x0143, 0x0122, 0x0102, 0x00E2, 0x00C2, 0x00C2, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x00A1, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0061, 0x0081, 0x00A1, 0x00A1, 0x00C1, 0x00E2, 0x0122, 0x0122, 0x00E2, 0x0081, 0x0061, 0x0081, 0x00C1, 0x0060, 0x0060, 0x00E2, 0x00E2, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0080, 0x00A1, 0x00C1, 0x00C1, 0x00C2, 0x00E1, 0x0162, 0x0162, 0x0163, 0x0163, 0x0183, 0x0183, 0x0183, 0x0183, 0x0163, 0x0122, 0x0102, 0x00E2, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x00C2, 0x00A1, 0x00A1, 0x0080, 0x0060, 0x0080, 0x00A0, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0081, 0x0081, 0x0080, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0061, 0x0081, 0x00A2, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00E1, 0x00E2, 0x00A2, 0x0081, 0x0061, 0x00A1, 0x00A1, 0x0060, 0x0040, 0x00A1, 0x0080, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0060, 0x00A1, 0x00C1, 0x00E2, 0x0122, 0x0122, 0x00E1, 0x00A1, 0x0102, 0x0142, 0x0162, 0x0162, 0x0183, 0x0183, 0x0183, 0x01A3, 0x01A3, 0x0163, 0x0142, 0x0122, 0x00E2, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0080, 0x00A0, 0x0080, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0060, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x00A2, 0x0061, 0x00A1, 0x0060, 0x00A1, 0x0080, 0x0040, 0x0020, 0x00A1, 0x0060, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0080, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C2, 0x00C1, 0x0102, 0x0142, 0x0142, 0x0183, 0x0183, 0x0183, 0x01A3, 0x01A3, 0x0183, 0x0162, 0x0122, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x00A0, 0x00A1, 0x0080, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0081, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0061, 0x00A1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x00C1, 0x0081, 0x0081, 0x0080, 0x0040, 0x0020, 0x0081, 0x0060, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x00A0, 0x00C1, 0x00C1, 0x00C2, 0x00C2, 0x0102, 0x0142, 0x0142, 0x0163, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x0182, 0x0142, 0x0121, 0x0101, 0x0101, 0x00E1, 0x00C1, 0x00A0, 0x0081, 0x0081, 0x0060, 0x0080, 0x00C0, 0x0080, 0x0060, 0x00A0, 0x0080, 0x0080, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0060, 0x00C2, 0x0102, 0x0122, 0x00E1, 0x00A1, 0x0081, 0x00A1, 0x00A1, 0x0081, 0x00E2, 0x0081, 0x0081, 0x0060, 0x0040, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0080, 0x00E1, 0x0102, 0x00E1, 0x0102, 0x00E2, 0x00E2, 0x0102, 0x0142, 0x0163, 0x0183, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x0162, 0x0142, 0x0122, 0x0101, 0x00E1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0060, 0x0060, 0x0080, 0x0060, 0x0060, 0x0080, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0060, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0081, 0x00E2, 0x0102, 0x0122, 0x00E2, 0x00A1, 0x00C2, 0x00A1, 0x0081, 0x0081, 0x00C1, 0x00A1, 0x0060, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0081, 0x00E2, 0x0102, 0x0102, 0x00C1, 0x0143, 0x01C4, 0x0101, 0x0102, 0x0142, 0x0142, 0x01A4, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x0182, 0x0142, 0x0122, 0x0101, 0x0101, 0x0101, 0x00E1, 0x00C1, 0x0080, 0x0060, 0x0081, 0x0060, 0x00A0, 0x0080, 0x0060, 0x0080, 0x0060, 0x0060, 0x0041, 0x0041, 0x0041, 0x0061, 0x0040, 0x0040, 0x0060, 0x0040, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0061, 0x0061, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0081, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0040, 0x0061, 0x0061, 0x0041, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0061, 0x0081, 0x00E2, 0x0163, 0x0163, 0x0122, 0x0102, 0x0102, 0x0081, 0x0080, 0x00A1, 0x00C1, 0x00A1, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0060, 0x00A1, 0x0080, 0x0060, 0x0102, 0x0205, 0x0163, 0x0102, 0x00C1, 0x0183, 0x0163, 0x01A4, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x0162, 0x0142, 0x0122, 0x0101, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x0080, 0x0060, 0x0061, 0x0060, 0x0060, 0x00A0, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0041, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0080, 0x0060, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0060, 0x0080, 0x0081, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0060, 0x00E1, 0x0163, 0x01A4, 0x0163, 0x0143, 0x0143, 0x00E2, 0x0060, 0x0081, 0x00A1, 0x00A1, 0x00A2, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0184, 0x01A4, 0x00C1, 0x0102, 0x00C1, 0x0163, 0x0143, 0x0183, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x0183, 0x0162, 0x0142, 0x0121, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00A0, 0x0080, 0x0061, 0x0081, 0x00A1, 0x0060, 0x0060, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0080, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0081, 0x0081, 0x0080, 0x0081, 0x0080, 0x0080, 0x0080, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0060, 0x0123, 0x01A4, 0x01A4, 0x0163, 0x0122, 0x0143, 0x00A1, 0x0060, 0x0081, 0x00C2, 0x0081, 0x0081, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0081, 0x0102, 0x00A1, 0x00A1, 0x0102, 0x00C1, 0x0102, 0x0142, 0x0183, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x0182, 0x0162, 0x0142, 0x0101, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00A0, 0x0061, 0x00A2, 0x0080, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0060, 0x0080, 0x0081, 0x0061, 0x0061, 0x0081, 0x0081, 0x0082, 0x0082, 0x00A2, 0x0082, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0081, 0x0143, 0x01C4, 0x0184, 0x0122, 0x0122, 0x00E2, 0x0080, 0x0040, 0x00A1, 0x00C2, 0x0060, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0081, 0x0081, 0x0060, 0x0060, 0x00C2, 0x00E2, 0x00C1, 0x0102, 0x0142, 0x0183, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x0183, 0x0162, 0x0121, 0x0121, 0x0122, 0x0121, 0x00C1, 0x0080, 0x0080, 0x0080, 0x00C1, 0x00A0, 0x00C1, 0x00C1, 0x00A1, 0x00C1, 0x00A1, 0x00A0, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0081, 0x0081, 0x0082, 0x0082, 0x0082, 0x00A2, 0x00A2, 0x0082, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x00A1, 0x0184, 0x01A4, 0x0143, 0x0102, 0x0102, 0x0081, 0x0060, 0x0040, 0x00A1, 0x00A1, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x00C1, 0x00E1, 0x0122, 0x0163, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x0182, 0x0142, 0x0122, 0x0122, 0x0121, 0x0121, 0x00A0, 0x00A1, 0x00A1, 0x00A1, 0x0101, 0x00E1, 0x00E1, 0x0101, 0x00C1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0060, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0081, 0x0081, 0x0082, 0x00A2, 0x0082, 0x00A2, 0x00A2, 0x0082, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0060, 0x0060, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x00A1, 0x0143, 0x0143, 0x00C1, 0x00A1, 0x00A1, 0x0060, 0x0081, 0x0060, 0x0061, 0x0060, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0060, 0x00A1, 0x00C1, 0x00E1, 0x0142, 0x0163, 0x0183, 0x0183, 0x01A3, 0x01A3, 0x0183, 0x0162, 0x0142, 0x0101, 0x0101, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00C2, 0x00C1, 0x0142, 0x0102, 0x0142, 0x0122, 0x0102, 0x0102, 0x0101, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0082, 0x0082, 0x0082, 0x0082, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0060, 0x00A1, 0x00A1, 0x0060, 0x0040, 0x0040, 0x0040, 0x0081, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0020, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0060, 0x0081, 0x00A1, 0x00C1, 0x00E1, 0x0122, 0x0142, 0x0163, 0x0183, 0x01A3, 0x01A3, 0x0182, 0x0162, 0x0122, 0x0101, 0x00E1, 0x0101, 0x0101, 0x0101, 0x0101, 0x00E2, 0x00E1, 0x0142, 0x0142, 0x0162, 0x0142, 0x0122, 0x0122, 0x0122, 0x0102, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0081, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0081, 0x0061, 0x0080, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x00A1, 0x00C1, 0x00E1, 0x0122, 0x0142, 0x0163, 0x0183, 0x0183, 0x0182, 0x0162, 0x0142, 0x0121, 0x0101, 0x0101, 0x0142, 0x0142, 0x0101, 0x00E1, 0x0122, 0x0142, 0x0142, 0x0183, 0x0143, 0x0183, 0x0142, 0x0142, 0x0142, 0x0122, 0x0122, 0x0101, 0x0101, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A0, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0080, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0081, 0x0081, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0081, 0x00A1, 0x00C1, 0x00E2, 0x0102, 0x0122, 0x0162, 0x0183, 0x0183, 0x0182, 0x0162, 0x0142, 0x0121, 0x0121, 0x0122, 0x0163, 0x0142, 0x0101, 0x0142, 0x0163, 0x0183, 0x0183, 0x01A3, 0x01A3, 0x01A3, 0x0183, 0x0183, 0x0163, 0x0163, 0x0142, 0x0142, 0x0122, 0x0101, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0061, 0x0061, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0081, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0081, 0x00A1, 0x00C1, 0x00E2, 0x00E2, 0x0122, 0x0142, 0x0162, 0x0182, 0x0162, 0x0162, 0x0142, 0x0142, 0x0142, 0x0142, 0x0163, 0x0122, 0x0142, 0x0183, 0x0183, 0x01A3, 0x01C4, 0x01C4, 0x01C4, 0x01C4, 0x01C4, 0x01A3, 0x01A3, 0x0183, 0x0163, 0x0162, 0x0142, 0x0122, 0x0101, 0x00E1, 0x00C1, 0x00A1, 0x0081, 0x0080, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0080, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0081, 0x0081, 0x0081, 0x00C1, 0x00C1, 0x00E1, 0x0122, 0x0142, 0x0142, 0x0162, 0x0142, 0x0142, 0x0142, 0x0142, 0x0142, 0x0142, 0x0183, 0x0183, 0x0183, 0x01A3, 0x01C4, 0x01E4, 0x01E4, 0x0204, 0x0205, 0x0204, 0x01E4, 0x01C4, 0x01C4, 0x01A3, 0x0183, 0x0163, 0x0162, 0x0142, 0x0101, 0x00E1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0081, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00C1, 0x0102, 0x0122, 0x0122, 0x0142, 0x0142, 0x0142, 0x0122, 0x0142, 0x0162, 0x0162, 0x0163, 0x0183, 0x01A3, 0x01C4, 0x01E4, 0x0204, 0x0205, 0x0205, 0x0205, 0x0205, 0x01E4, 0x01E4, 0x01C4, 0x01A3, 0x0183, 0x0163, 0x0162, 0x0122, 0x0101, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00E1, 0x00E1, 0x0101, 0x0121, 0x0121, 0x0122, 0x0122, 0x0142, 0x0142, 0x0142, 0x0163, 0x0183, 0x01A3, 0x01C4, 0x01E4, 0x0205, 0x0205, 0x0205, 0x0205, 0x0204, 0x01E4, 0x01C4, 0x01C3, 0x0183, 0x0163, 0x0162, 0x0142, 0x0122, 0x0101, 0x00E1, 0x00C1, 0x00A1, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0080, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0060, 0x0060,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0020, 0x0020, 0x0020, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00E1, 0x0101, 0x0101, 0x0101, 0x0122, 0x0122, 0x0142, 0x0142, 0x0162, 0x0183, 0x01A3, 0x01C4, 0x01E4, 0x01E4, 0x01E4, 0x01E4, 0x01E4, 0x01E4, 0x01C4, 0x01C3, 0x0183, 0x0162, 0x0162, 0x0142, 0x0121, 0x0101, 0x00E1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0080, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x0080, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0060,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0080, 0x0080, 0x0060, 0x0081, 0x0080, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x0101, 0x0122, 0x0142, 0x0142, 0x0162, 0x0183, 0x01A3, 0x01C4, 0x01C4, 0x01E4, 0x01C4, 0x01C4, 0x01C4, 0x01C4, 0x01A3, 0x0183, 0x0162, 0x0142, 0x0142, 0x0121, 0x0101, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0061, 0x0061, 0x0081, 0x0080, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0061, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0080, 0x0060, 0x0060, 0x0060, 0x0081, 0x0080, 0x0081, 0x0081, 0x00C1, 0x00C1, 0x00E1, 0x0122, 0x0122, 0x0122, 0x0142, 0x0142, 0x0163, 0x0183, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x01A3, 0x0183, 0x0162, 0x0142, 0x0142, 0x0121, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0081, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0081, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0081, 0x0080, 0x0080, 0x00A1, 0x00E2, 0x0122, 0x0122, 0x0122, 0x0122, 0x0142, 0x0163, 0x0163, 0x0183, 0x0183, 0x0183, 0x0183, 0x0183, 0x0183, 0x0183, 0x0142, 0x0142, 0x0121, 0x0101, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0081, 0x0080, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0081, 0x00E2, 0x00E1, 0x0102, 0x0101, 0x0122, 0x0122, 0x0122, 0x0142, 0x0143, 0x0163, 0x0163, 0x0163, 0x0183, 0x0183, 0x0183, 0x0162, 0x0142, 0x0121, 0x0101, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0081, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0081, 0x00A1, 0x0122, 0x0122, 0x0122, 0x0122, 0x0102, 0x0122, 0x0142, 0x0142, 0x0142, 0x0142, 0x0162, 0x0163, 0x0162, 0x0142, 0x0122, 0x0121, 0x0101, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x00A1, 0x0143, 0x0163, 0x0142, 0x00E1, 0x0163, 0x0163, 0x0101, 0x0101, 0x0142, 0x0122, 0x0142, 0x0142, 0x0142, 0x0142, 0x0142, 0x0122, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0080, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0060, 0x0081, 0x00A1, 0x0102, 0x0143, 0x01C5, 0x00E1, 0x0102, 0x01C4, 0x0183, 0x00C1, 0x00E1, 0x0142, 0x00E1, 0x0122, 0x0122, 0x0142, 0x0142, 0x0122, 0x0101, 0x0101, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0060, 0x00A1, 0x00C1, 0x00E2, 0x0102, 0x01C5, 0x00E2, 0x0080, 0x0184, 0x01C4, 0x0142, 0x00A1, 0x00A1, 0x0142, 0x00E1, 0x0122, 0x0122, 0x0122, 0x0122, 0x0122, 0x0101, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E2, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0061, 0x00C2, 0x00E2, 0x00E2, 0x00E2, 0x00C1, 0x00A1, 0x0060, 0x00C1, 0x0102, 0x00E2, 0x00A1, 0x00C1, 0x0123, 0x0102, 0x0102, 0x0122, 0x0102, 0x0102, 0x0102, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x0102, 0x0102, 0x0102, 0x0102, 0x0102, 0x00E2, 0x00E2, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00E2, 0x00E1, 0x00E1, 0x00E2, 0x00E1, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0041, 0x0061, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0060, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0081, 0x00C1, 0x00E1, 0x00A1, 0x0081, 0x00C1, 0x0060, 0x0060, 0x0060, 0x0080, 0x00C1, 0x00A1, 0x00A1, 0x00E2, 0x00E2, 0x00E1, 0x00E1, 0x00E1, 0x0102, 0x00E2, 0x00E1, 0x00E1, 0x0102, 0x0102, 0x0122, 0x0122, 0x0122, 0x0122, 0x0122, 0x0102, 0x00E2, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E2, 0x00E1, 0x0101, 0x0102, 0x0101, 0x0101, 0x0101, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0080, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0060, 0x00A1, 0x00C1, 0x00C1, 0x0081, 0x0081, 0x0080, 0x0060, 0x0080, 0x0060, 0x0080, 0x0102, 0x0080, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x0101, 0x0122, 0x0142, 0x0142, 0x0143, 0x0143, 0x0143, 0x0142, 0x0122, 0x0102, 0x0102, 0x00E2, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x0102, 0x0101, 0x0101, 0x0101, 0x0101, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0080, 0x0081, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0041,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0081, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0081, 0x0060, 0x0080, 0x0060, 0x0080, 0x0081, 0x0080, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x0102, 0x0122, 0x0142, 0x0143, 0x0163, 0x0183, 0x0183, 0x0163, 0x0143, 0x0142, 0x0122, 0x0102, 0x0102, 0x00E2, 0x00E2, 0x00E1, 0x00E1, 0x00E1, 0x0101, 0x0101, 0x0121, 0x0121, 0x0121, 0x0121, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0081, 0x0080, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x0122, 0x0142, 0x0162, 0x0183, 0x01A3, 0x01A3, 0x01A3, 0x0183, 0x0163, 0x0143, 0x0122, 0x0102, 0x0102, 0x0102, 0x00E2, 0x00E1, 0x0101, 0x0101, 0x0101, 0x0101, 0x0101, 0x0121, 0x0121, 0x0121, 0x0101, 0x0101, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0060, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x00A1, 0x0081, 0x00A1, 0x00C1, 0x0081, 0x0060, 0x0060, 0x0040, 0x0060, 0x0081, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00C1, 0x00E1, 0x0102, 0x0102, 0x0122, 0x0142, 0x0163, 0x01A3, 0x01A4, 0x01C4, 0x01A3, 0x01A3, 0x0183, 0x0163, 0x0142, 0x0102, 0x0102, 0x0102, 0x0102, 0x0101, 0x00E1, 0x0101, 0x0101, 0x0101, 0x0101, 0x0122, 0x0121, 0x0121, 0x0121, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A0, 0x0080, 0x0080, 0x0060, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0041,
0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0081, 0x00A1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x00A1, 0x0081, 0x0081, 0x00A1, 0x0080, 0x0060, 0x0040, 0x0040, 0x0040, 0x0060, 0x0080, 0x0081, 0x00C1, 0x00C1, 0x00E1, 0x0102, 0x0102, 0x0122, 0x0142, 0x0163, 0x0183, 0x01A4, 0x01C4, 0x01C4, 0x01A4, 0x01A3, 0x0183, 0x0163, 0x0142, 0x0122, 0x0122, 0x0102, 0x0101, 0x0101, 0x0101, 0x0101, 0x0101, 0x0101, 0x0101, 0x0121, 0x0122, 0x0121, 0x0121, 0x0101, 0x0101, 0x00E1, 0x00C1, 0x00C1, 0x00A0, 0x00A0, 0x0080, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0041,
0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0080, 0x00A1, 0x00C1, 0x00E1, 0x00E2, 0x0102, 0x0122, 0x0142, 0x0143, 0x0163, 0x01A3, 0x01C4, 0x01C4, 0x01C4, 0x01C4, 0x01A3, 0x0183, 0x0163, 0x0142, 0x0122, 0x0122, 0x0101, 0x00E1, 0x00E1, 0x00E1, 0x0101, 0x0101, 0x0101, 0x0101, 0x0121, 0x0121, 0x0121, 0x0121, 0x0121, 0x0101, 0x00E1, 0x00C1, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0041, 0x0041,
0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0081, 0x00A1, 0x0081, 0x00A2, 0x00A2, 0x0081, 0x0081, 0x0080, 0x0080, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0080, 0x00A1, 0x00C1, 0x00C1, 0x00E2, 0x0102, 0x0122, 0x0142, 0x0163, 0x0183, 0x01A4, 0x01C4, 0x01C4, 0x01C4, 0x01C4, 0x01A3, 0x0183, 0x0183, 0x0142, 0x0121, 0x0121, 0x0101, 0x00E1, 0x00C1, 0x00E1, 0x00E2, 0x0102, 0x0101, 0x0121, 0x0121, 0x0121, 0x0121, 0x0121, 0x0101, 0x0101, 0x00E1, 0x00C1, 0x00A0, 0x00A0, 0x0060, 0x0080, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0041,
0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A2, 0x00C3, 0x00A2, 0x00A1, 0x00A1, 0x0081, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0080, 0x0081, 0x00A1, 0x00C1, 0x00E1, 0x00E2, 0x0122, 0x0142, 0x0163, 0x0183, 0x01A4, 0x01E4, 0x01E4, 0x01C4, 0x01A4, 0x01A3, 0x0183, 0x0163, 0x0142, 0x0121, 0x0101, 0x0122, 0x00E1, 0x00C1, 0x00C1, 0x00E1, 0x0101, 0x0101, 0x0121, 0x0121, 0x0121, 0x0121, 0x0121, 0x0101, 0x0101, 0x00E1, 0x00C1, 0x00A1, 0x00A0, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040,
0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0081, 0x00C1, 0x00C1, 0x00C1, 0x00C2, 0x00C3, 0x00E3, 0x00C2, 0x00A1, 0x00A1, 0x0080, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0081, 0x0081, 0x00A1, 0x00C1, 0x00E1, 0x0102, 0x0142, 0x0163, 0x0183, 0x01C4, 0x01E4, 0x01C4, 0x01C4, 0x01A3, 0x0183, 0x0183, 0x0142, 0x0142, 0x0122, 0x0101, 0x0102, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x0101, 0x0101, 0x0101, 0x0121, 0x0121, 0x0121, 0x0101, 0x0101, 0x0101, 0x00E1, 0x00C1, 0x00A0, 0x0080, 0x0060, 0x0060, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0021, 0x0021, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0061, 0x0081, 0x00A1, 0x00C1, 0x00E2, 0x00A1, 0x00A1, 0x00C2, 0x00E2, 0x00C1, 0x00A1, 0x00A1, 0x0080, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0081, 0x00A1, 0x00C1, 0x0102, 0x0143, 0x0183, 0x0183, 0x01A4, 0x01C4, 0x01C4, 0x01C4, 0x01A3, 0x0183, 0x0163, 0x0142, 0x0122, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00E2, 0x0102, 0x00E1, 0x0101, 0x0101, 0x0121, 0x0121, 0x0101, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00A0, 0x0080, 0x0060, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A1, 0x0080, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0041, 0x0041, 0x0041, 0x0041, 0x0021, 0x0021, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0061, 0x0081, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x00A1, 0x00C1, 0x00A1, 0x00A0, 0x0081, 0x0080, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x00A1, 0x00E1, 0x0102, 0x0122, 0x0163, 0x0183, 0x01A4, 0x01C4, 0x01C4, 0x01A4, 0x01A3, 0x0183, 0x0163, 0x0142, 0x0122, 0x0102, 0x00E2, 0x0102, 0x00C1, 0x00E1, 0x0102, 0x0101, 0x0101, 0x0101, 0x0101, 0x0101, 0x0121, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00C0, 0x00A0, 0x0080, 0x0061, 0x0061, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0021, 0x0021, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0060, 0x0081, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x00C1, 0x00A0, 0x0080, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x00A1, 0x00C1, 0x0102, 0x0122, 0x0143, 0x0183, 0x01A4, 0x01A4, 0x01A3, 0x01A3, 0x0183, 0x0163, 0x0142, 0x0122, 0x0102, 0x00E1, 0x00E2, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x0101, 0x0101, 0x0101, 0x0101, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00A0, 0x00A0, 0x0081, 0x0081, 0x0081, 0x0061, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0081, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x00A1, 0x00A0, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0021, 0x0021, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00A1, 0x0082, 0x0081, 0x0081, 0x0080, 0x0080, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x00C1, 0x00E1, 0x0102, 0x0142, 0x0163, 0x0183, 0x01A3, 0x01A3, 0x01A3, 0x0183, 0x0163, 0x0143, 0x0122, 0x0102, 0x00E1, 0x00E1, 0x00C1, 0x00A1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x0101, 0x0101, 0x0101, 0x0101, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0061, 0x0060, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0060, 0x0060, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0080, 0x0081, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0021, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x00A1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0081, 0x00E1, 0x0102, 0x0122, 0x0143, 0x0163, 0x0163, 0x01A3, 0x0183, 0x0183, 0x0163, 0x0163, 0x0142, 0x0122, 0x0121, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00C0, 0x00C1, 0x00C0, 0x00C1, 0x00E1, 0x0101, 0x0101, 0x0101, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x0080, 0x0081, 0x0081, 0x0081, 0x0061, 0x0060, 0x0060, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0081, 0x00A0, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x0081, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x00A1, 0x0080, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x0080, 0x0080, 0x00A1, 0x00C1, 0x00E1, 0x0101, 0x0122, 0x0142, 0x0163, 0x0183, 0x0183, 0x0163, 0x0163, 0x0142, 0x0121, 0x0102, 0x0101, 0x00E1, 0x0080, 0x00C1, 0x00C1, 0x00C1, 0x00A0, 0x00A0, 0x00C1, 0x00E1, 0x00E1, 0x0101, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0081, 0x0061, 0x0061, 0x0080, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00A0, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x0081, 0x00C1, 0x00E1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x00A1, 0x00C1, 0x00A0, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0080, 0x00A1, 0x00C0, 0x00C1, 0x00C1, 0x00E1, 0x0101, 0x0102, 0x0122, 0x0143, 0x0163, 0x0163, 0x0163, 0x0142, 0x0122, 0x0101, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00A0, 0x00A1, 0x00C0, 0x00A0, 0x00A0, 0x00C1, 0x00E1, 0x00E1, 0x0101, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0080, 0x0080, 0x00A0, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0061, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x00C2, 0x00E1, 0x00C1, 0x0080, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0080, 0x00C0, 0x00C1, 0x00C1, 0x0101, 0x0122, 0x0102, 0x0122, 0x0143, 0x0143, 0x0143, 0x0142, 0x0122, 0x0102, 0x0101, 0x00E1, 0x00A1, 0x00C1, 0x00E1, 0x0080, 0x0080, 0x00C0, 0x00C0, 0x00A0, 0x00C0, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A0, 0x00A0, 0x00A1, 0x00A0, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0061, 0x00A1, 0x00C1, 0x0102, 0x0102, 0x00C1, 0x0081, 0x0081, 0x00C1, 0x0101, 0x00E1, 0x0080, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x00A0, 0x00C0, 0x00E1, 0x0122, 0x0122, 0x0121, 0x0122, 0x0122, 0x0142, 0x0142, 0x0122, 0x0122, 0x00E2, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00C1, 0x00E1, 0x0081, 0x00A0, 0x00C0, 0x00C0, 0x00A0, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040, 0x0060, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0081, 0x00E2, 0x0102, 0x0122, 0x0102, 0x00C1, 0x00A1, 0x0081, 0x00C1, 0x00E1, 0x00E1, 0x00A0, 0x0060, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0060, 0x0080, 0x00A1, 0x00E1, 0x00C1, 0x00A0, 0x00A1, 0x00E1, 0x0122, 0x0142, 0x0122, 0x0122, 0x0122, 0x0122, 0x0122, 0x0102, 0x00E1, 0x00E1, 0x00C1, 0x00A1, 0x0080, 0x00A0, 0x00C0, 0x00C1, 0x0080, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x0101, 0x0101, 0x0101, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0061, 0x00A1, 0x00E2, 0x0122, 0x0102, 0x00E1, 0x00E2, 0x00C1, 0x0081, 0x00C1, 0x00E1, 0x00C1, 0x00A0, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0041, 0x0040, 0x0060, 0x00A1, 0x00C1, 0x00E1, 0x0102, 0x0143, 0x0122, 0x00E1, 0x00E1, 0x0101, 0x0122, 0x0122, 0x0101, 0x0101, 0x00E2, 0x00C1, 0x00C2, 0x00C2, 0x00C1, 0x00A2, 0x00A2, 0x00C4, 0x0081, 0x00A2, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C0, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x0101, 0x0101, 0x0101, 0x0101, 0x0101, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0061, 0x00C2, 0x00E2, 0x00C1, 0x00A1, 0x00C1, 0x00E2, 0x00C1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00A0, 0x0080, 0x0080, 0x0060, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00E1, 0x0122, 0x0121, 0x0142, 0x0122, 0x0122, 0x0142, 0x00E1, 0x00C1, 0x00E1, 0x00E1, 0x0101, 0x0102, 0x00E1, 0x00C1, 0x00A1, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x00A2, 0x0081, 0x0081, 0x00C3, 0x0104, 0x0081, 0x00A1, 0x00C2, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x0101, 0x0101, 0x0102, 0x0102, 0x0122, 0x0101, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0061, 0x0081, 0x00A1, 0x0080, 0x0080, 0x00E2, 0x0102, 0x00E1, 0x0080, 0x00A0, 0x00A1, 0x00E1, 0x00A1, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0081, 0x00A2, 0x00E2, 0x00E1, 0x0101, 0x0101, 0x0101, 0x0142, 0x0942, 0x0142, 0x00E1, 0x0101, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00C1, 0x00C1, 0x00A0, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x0101, 0x0102, 0x0102, 0x0122, 0x0102, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0081, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x00A1, 0x00E2, 0x00C2, 0x00C1, 0x00A1, 0x0080, 0x00A1, 0x00E1, 0x00C1, 0x0080, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x00E1, 0x0101, 0x00E2, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x00C1, 0x00E1, 0x00E1, 0x00C1, 0x0060, 0x0060, 0x0040, 0x00A0, 0x00A0, 0x0080, 0x0060, 0x0060, 0x0060, 0x0082, 0x0062, 0x0061, 0x0060, 0x0080, 0x0080, 0x00A0, 0x00A1, 0x00E2, 0x00E2, 0x00E1, 0x00E1, 0x00E1, 0x0101, 0x0101, 0x0102, 0x0102, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A0, 0x00A0, 0x0081, 0x0081, 0x0080, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x00C1, 0x00C1, 0x0080, 0x00A1, 0x00C1, 0x0080, 0x0080, 0x00C1, 0x00C1, 0x0081, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00E1, 0x00C0, 0x00A0, 0x0080, 0x0061, 0x0061, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0060, 0x0060, 0x0080, 0x00A1, 0x0080, 0x0080, 0x0040, 0x0060, 0x0060, 0x0080, 0x0083, 0x0041, 0x0081, 0x00A0, 0x00A1, 0x0080, 0x0080, 0x00A0, 0x00A1, 0x00C1, 0x00E2, 0x00E1, 0x00E1, 0x00E1, 0x0102, 0x0102, 0x0101, 0x0101, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A0, 0x00A1, 0x00A1, 0x0081, 0x0080, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x0060, 0x00A1, 0x00E2, 0x00A1, 0x0080, 0x00A1, 0x00C1, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0081, 0x00E2, 0x0102, 0x00E1, 0x00C0, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0060, 0x0081, 0x00A1, 0x0080, 0x0080, 0x00C1, 0x0081, 0x00A1, 0x0060, 0x0040, 0x00A1, 0x00A1, 0x0060, 0x0040, 0x0040, 0x0081, 0x00C1, 0x0080, 0x0080, 0x0081, 0x0060, 0x0040, 0x0040, 0x0040, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00C1, 0x00E2, 0x00E2, 0x00E2, 0x0102, 0x0102, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0080, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0081, 0x0081, 0x00A1, 0x0080, 0x0060, 0x00C1, 0x0102, 0x00C1, 0x0081, 0x0081, 0x00A1, 0x0081, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x00A1, 0x0102, 0x0122, 0x00E1, 0x00C0, 0x00C0, 0x00C1, 0x00E2, 0x0081, 0x0060, 0x00C1, 0x00A0, 0x0040, 0x00A1, 0x0081, 0x00A1, 0x0060, 0x0040, 0x0060, 0x0081, 0x0040, 0x0040, 0x0040, 0x00C1, 0x0081, 0x0080, 0x00A1, 0x00A1, 0x0040, 0x0060, 0x0080, 0x0060, 0x00A1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00E2, 0x00E1, 0x00E1, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x00A1, 0x00A0, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0080, 0x0081, 0x0081, 0x0081, 0x00C1, 0x00E2, 0x00E2, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00E1, 0x0102, 0x0183, 0x0184, 0x00A1, 0x0080, 0x00E1, 0x0081, 0x0060, 0x00C1, 0x0060, 0x0040, 0x0040, 0x0020, 0x0040, 0x0020, 0x0020, 0x0060, 0x0081, 0x0060, 0x0040, 0x0020, 0x0040, 0x0081, 0x00E2, 0x0081, 0x0060, 0x0080, 0x0080, 0x0060, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00E1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00A0, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0061, 0x0081, 0x0081, 0x00A1, 0x00E2, 0x00C2, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00C2, 0x00E1, 0x00C1, 0x01A4, 0x0225, 0x0142, 0x0060, 0x00A1, 0x00A1, 0x0061, 0x00A1, 0x00C1, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0081, 0x00A1, 0x00A1, 0x0060, 0x0060, 0x0060, 0x0060, 0x00A1, 0x0081, 0x0040, 0x0060, 0x00A2, 0x00C3, 0x0082, 0x0081, 0x00A1, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x0081, 0x0081, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C2, 0x00C2, 0x00A1, 0x00A1, 0x00A2, 0x00A2, 0x0081, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00C2, 0x00A1, 0x00C2, 0x0164, 0x0184, 0x00C0, 0x0060, 0x00C1, 0x0081, 0x0060, 0x0080, 0x0081, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x00A1, 0x00C1, 0x0080, 0x0040, 0x0040, 0x0060, 0x0060, 0x0082, 0x0062, 0x00A2, 0x0061, 0x0080, 0x0080, 0x0080, 0x0080, 0x00C1, 0x00A1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0081, 0x0081, 0x0081, 0x00C2, 0x00C2, 0x00C2, 0x00C2, 0x00A2, 0x00A1, 0x00A2, 0x00A2, 0x00A2, 0x00A2, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00A1, 0x0080, 0x0080, 0x00E1, 0x0060, 0x0040, 0x00A1, 0x0081, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0080, 0x0060, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0040, 0x0062, 0x00E5, 0x08E5, 0x0061, 0x0081, 0x0060, 0x0080, 0x0080, 0x0081, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00C1, 0x00C2, 0x00C2, 0x00E2, 0x00E2, 0x00E2, 0x00C2, 0x00A2, 0x00A2, 0x00A2, 0x0082, 0x00A2, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00C1, 0x00C2, 0x00A1, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x0060, 0x0040, 0x0081, 0x0060, 0x0040, 0x0020, 0x0020, 0x0081, 0x00E2, 0x0103, 0x0123, 0x0144, 0x00E2, 0x0080, 0x0080, 0x0080, 0x0060, 0x0040, 0x0061, 0x0060, 0x0040, 0x0020, 0x0060, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C2, 0x00E2, 0x00E3, 0x00E3, 0x00C2, 0x00A2, 0x00A2, 0x0081, 0x0081, 0x0082, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0081, 0x00A1, 0x00C1, 0x00E2, 0x00A2, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x0081, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0081, 0x00A1, 0x00A1, 0x0080, 0x0081, 0x00E2, 0x0102, 0x00C1, 0x0080, 0x0060, 0x0040, 0x0061, 0x00A4, 0x0083, 0x0062, 0x0040, 0x0040, 0x0060, 0x0040, 0x0060, 0x0080, 0x0080, 0x0080, 0x0081, 0x00C2, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0060, 0x0041, 0x0041, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C2, 0x00C2, 0x00C2, 0x00C2, 0x00A2, 0x0081, 0x0082, 0x0081, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x00C1, 0x00C2, 0x00C2, 0x00A1, 0x0061, 0x0081, 0x00A1, 0x0081, 0x0061, 0x0061, 0x0060, 0x0040, 0x0061, 0x00E3, 0x00A1, 0x0080, 0x0040, 0x0060, 0x00A0, 0x00C1, 0x00E2, 0x00A1, 0x0060, 0x0080, 0x0061, 0x0082, 0x0041, 0x0061, 0x0040, 0x00A0, 0x0060, 0x0040, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0081, 0x0080, 0x0060, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0080, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0061, 0x0041, 0x0040, 0x0041, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x00A1, 0x00C1, 0x00A1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C2, 0x00C2, 0x00A2, 0x0081, 0x0081, 0x0061, 0x0061, 0x0081, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0080, 0x00A1, 0x00A1, 0x00C2, 0x00A2, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x00C2, 0x0061, 0x0061, 0x0061, 0x0060, 0x0081, 0x00C2, 0x0103, 0x0123, 0x0102, 0x00C1, 0x0040, 0x0060, 0x0080, 0x0080, 0x0061, 0x0107, 0x0083, 0x0040, 0x0080, 0x0020, 0x00A1, 0x0040, 0x0040, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0081, 0x0041, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0080, 0x0081, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0060, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0041, 0x0061, 0x0061, 0x0081, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0041, 0x0061, 0x0081, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0060, 0x0060, 0x0081, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x00A1, 0x0102, 0x00E2, 0x00C2, 0x00C1, 0x00E1, 0x00E1, 0x00A0, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x0060, 0x0040, 0x0082, 0x00C4, 0x0060, 0x0040, 0x0060, 0x0080, 0x0020, 0x0080, 0x0060, 0x0020, 0x0060, 0x0040, 0x0060, 0x0080, 0x00A1, 0x0081, 0x0082, 0x0060, 0x0060, 0x0080, 0x0060, 0x0060, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0081, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0040, 0x0061, 0x0081, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0060, 0x0060, 0x0060, 0x0061, 0x0081, 0x00A1, 0x0081, 0x0081, 0x00A1, 0x00C1, 0x0081, 0x0081, 0x0060, 0x0081, 0x0122, 0x0122, 0x0080, 0x0040, 0x0040, 0x00A1, 0x0080, 0x0060, 0x0060, 0x0040, 0x0061, 0x0083, 0x00A4, 0x00A2, 0x0060, 0x0080, 0x0060, 0x00A1, 0x0020, 0x0060, 0x0080, 0x0040, 0x0080, 0x00A1, 0x00A0, 0x0080, 0x0060, 0x0060, 0x0061, 0x0061, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0080, 0x0081, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0081, 0x00A2, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C2, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0061, 0x0061, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0060, 0x0081, 0x0081, 0x00E1, 0x0102, 0x00C1, 0x00A1, 0x00A0, 0x00E2, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0041, 0x0020, 0x0080, 0x0080, 0x0060, 0x0080, 0x0060, 0x0080, 0x0020, 0x0020, 0x00A1, 0x0081, 0x0080, 0x0080, 0x0040, 0x0040, 0x0060, 0x0060, 0x0061, 0x0060, 0x0080, 0x0040, 0x0060, 0x0080, 0x0060, 0x0081, 0x0060, 0x0081, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x0081, 0x0080, 0x0081, 0x0081, 0x0081, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A2, 0x00A1, 0x0081, 0x0081, 0x0061, 0x0061, 0x0081, 0x0081, 0x0061, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0081, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0061, 0x0081, 0x00A1, 0x0103, 0x0123, 0x0143, 0x00C1, 0x00E1, 0x00E1, 0x00A1, 0x0080, 0x00A1, 0x0060, 0x0080, 0x0040, 0x0040, 0x00A1, 0x0062, 0x0063, 0x0041, 0x0040, 0x00C1, 0x0060, 0x0060, 0x0060, 0x0080, 0x0060, 0x0020, 0x0020, 0x00A1, 0x0061, 0x0040, 0x0020, 0x0040, 0x0060, 0x0040, 0x21A6, 0x0082, 0x0020, 0x00A1, 0x0040, 0x0040, 0x0060, 0x0080, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x0080, 0x00A1, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0060, 0x0081, 0x0061, 0x0061, 0x0060, 0x0061, 0x0060, 0x0060, 0x0060, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0061, 0x0060, 0x0061, 0x0081, 0x00A1, 0x00C2, 0x00C2, 0x00C2, 0x00C2, 0x00C2, 0x00C2, 0x00A1, 0x0081, 0x0081, 0x0061, 0x0060, 0x0081, 0x0081, 0x0061, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0061, 0x0081, 0x0082, 0x00C2, 0x00E3, 0x00C2, 0x00C2, 0x00C2, 0x00C2, 0x0144, 0x00C2, 0x00A0, 0x0080, 0x0060, 0x0080, 0x0060, 0x0060, 0x0040, 0x0081, 0x0020, 0x0060, 0x0040, 0x00C1, 0x0060, 0x0080, 0x0040, 0x00A1, 0x0060, 0x0040, 0x0020, 0x0061, 0x0060, 0x0040, 0x0040, 0x0081, 0x0080, 0x0060, 0x1145, 0x1966, 0x0061, 0x0080, 0x0080, 0x0040, 0x0040, 0x0060, 0x0081, 0x0060, 0x0060, 0x0080, 0x0080, 0x0060, 0x0060, 0x0080, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0081, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0060, 0x0080, 0x0060, 0x0080, 0x0081, 0x0080, 0x0080, 0x0080, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00E2, 0x0103, 0x0103, 0x0102, 0x00E2, 0x00C2, 0x00A1, 0x00A1, 0x00A2, 0x00A1, 0x0081, 0x0081, 0x0061, 0x0061, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A2, 0x0061, 0x0061, 0x00A2, 0x00C3, 0x00C2, 0x00C2, 0x00C3, 0x0080, 0x00C1, 0x00C1, 0x00A0, 0x0080, 0x0061, 0x00C2, 0x0080, 0x08C3, 0x0062, 0x00A2, 0x0060, 0x0040, 0x00C1, 0x0040, 0x00A1, 0x0040, 0x00A0, 0x0040, 0x0040, 0x0080, 0x0060, 0x0061, 0x0081, 0x0081, 0x0041, 0x0080, 0x00A0, 0x0060, 0x0040, 0x0060, 0x00A3, 0x08A3, 0x0060, 0x00A1, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C2, 0x00C1, 0x00E2, 0x0103, 0x0103, 0x0103, 0x0102, 0x00E2, 0x00E2, 0x00C2, 0x0104, 0x00E4, 0x00A2, 0x0081, 0x0081, 0x0081, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00A2, 0x00C2, 0x0081, 0x0081, 0x00A2, 0x0123, 0x0143, 0x0123, 0x00E2, 0x0081, 0x00A1, 0x0080, 0x00A0, 0x0080, 0x0080, 0x0061, 0x08A3, 0x08C3, 0x0082, 0x00A2, 0x0060, 0x0040, 0x00C1, 0x0060, 0x00C2, 0x0040, 0x00C1, 0x0040, 0x0040, 0x00A1, 0x0061, 0x0061, 0x0081, 0x0061, 0x00A1, 0x00A0, 0x0060, 0x0060, 0x00A1, 0x0040, 0x0083, 0x0080, 0x0020, 0x0060, 0x0080, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0061, 0x0081, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0080, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080,
0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0061, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x00A1, 0x00A1, 0x00C2, 0x00E2, 0x0102, 0x0102, 0x00E2, 0x0102, 0x00E2, 0x00E2, 0x0102, 0x0102, 0x00E2, 0x00E2, 0x0925, 0x0946, 0x0904, 0x00A2, 0x0081, 0x00A1, 0x0081, 0x0060, 0x0060, 0x0040, 0x0040, 0x0061, 0x0061, 0x0060, 0x0060, 0x0061, 0x0081, 0x0081, 0x0081, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0144, 0x0164, 0x0185, 0x0123, 0x00E1, 0x0102, 0x0102, 0x0142, 0x0102, 0x0122, 0x0102, 0x0080, 0x0060, 0x00A3, 0x0905, 0x00E2, 0x00A0, 0x0082, 0x00E5, 0x00C1, 0x0080, 0x0123, 0x0060, 0x0080, 0x0020, 0x00A1, 0x0040, 0x0041, 0x00A1, 0x0061, 0x0061, 0x0041, 0x0081, 0x00A1, 0x0040, 0x00A1, 0x00A1, 0x0060, 0x0040, 0x0082, 0x0060, 0x00A1, 0x0020, 0x0040, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0080, 0x00A1, 0x0080, 0x0080, 0x0080,
0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0060, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00E2, 0x0102, 0x0102, 0x00E2, 0x00E2, 0x00C1, 0x00A1, 0x00C1, 0x00E2, 0x00E2, 0x00C1, 0x0104, 0x0946, 0x0926, 0x00C3, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A2, 0x0081, 0x0061, 0x00A1, 0x00C2, 0x00A2, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x00A1, 0x00A1, 0x0103, 0x0123, 0x0102, 0x00C1, 0x00A1, 0x00A1, 0x0164, 0x0143, 0x0143, 0x00E2, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00A1, 0x00C6, 0x00E5, 0x00E2, 0x00C1, 0x00A0, 0x0061, 0x00A2, 0x00C1, 0x00E1, 0x00C1, 0x0040, 0x0080, 0x0020, 0x00C1, 0x0060, 0x0041, 0x0061, 0x0041, 0x0040, 0x0020, 0x0040, 0x0040, 0x00E2, 0x0081, 0x00A1, 0x0080, 0x0040, 0x0081, 0x0040, 0x00C1, 0x0040, 0x0020, 0x0060, 0x0080, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0080, 0x0081, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x0080,
0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00E2, 0x00C2, 0x00A1, 0x00A1, 0x00A1, 0x00E2, 0x00E2, 0x00A1, 0x00C2, 0x00E4, 0x0105, 0x00A2, 0x0081, 0x00A1, 0x00C2, 0x00E3, 0x0103, 0x00E3, 0x00A2, 0x0081, 0x0103, 0x0103, 0x00E3, 0x00E3, 0x00E3, 0x00C2, 0x00C2, 0x00A2, 0x0081, 0x0081, 0x0123, 0x0163, 0x0184, 0x0183, 0x0102, 0x00A1, 0x00E1, 0x0143, 0x0122, 0x0101, 0x0080, 0x0080, 0x0061, 0x0082, 0x00A1, 0x00E1, 0x0102, 0x0040, 0x0061, 0x0041, 0x0080, 0x0101, 0x0080, 0x0040, 0x0080, 0x0040, 0x0082, 0x0081, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0061, 0x0124, 0x0061, 0x0080, 0x0081, 0x0041, 0x0020, 0x0041, 0x0080, 0x0040, 0x0082, 0x0020, 0x0040, 0x00A1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x00A1, 0x0080, 0x0080, 0x0081, 0x0080, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A0, 0x0080,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0060, 0x00A1, 0x00E2, 0x00E2, 0x00E2, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x00A2, 0x00C2, 0x00C2, 0x00A2, 0x00A1, 0x00A1, 0x00A2, 0x00A2, 0x00A2, 0x00A2, 0x00A2, 0x00C2, 0x0082, 0x0081, 0x0081, 0x00A1, 0x00C1, 0x00E2, 0x00E3, 0x00E3, 0x00C2, 0x00A1, 0x00C2, 0x00E2, 0x00C2, 0x0103, 0x0124, 0x00E2, 0x00E2, 0x00C2, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x00C2, 0x0123, 0x0142, 0x0122, 0x00C1, 0x00A0, 0x0060, 0x0062, 0x0084, 0x0042, 0x00C1, 0x0080, 0x0060, 0x00C2, 0x00A1, 0x00A0, 0x0041, 0x00E2, 0x00C1, 0x00A1, 0x0040, 0x0060, 0x0040, 0x0040, 0x0061, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x00E2, 0x0040, 0x0080, 0x00A1, 0x0061, 0x10C2, 0x1102, 0x0041, 0x0080, 0x0020, 0x0882, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x0080, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A0, 0x00A0, 0x0080,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x00C1, 0x00E2, 0x00E2, 0x00C1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00C2, 0x00C2, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00A2, 0x00A2, 0x0081, 0x0061, 0x0061, 0x0081, 0x00A2, 0x00C2, 0x00A2, 0x00A2, 0x00A2, 0x00C2, 0x00C2, 0x00A1, 0x00A1, 0x00C2, 0x00E2, 0x0102, 0x00C2, 0x00A1, 0x00E2, 0x0185, 0x0185, 0x01C5, 0x01A5, 0x0164, 0x0103, 0x00A2, 0x0061, 0x00C1, 0x0102, 0x0122, 0x0083, 0x00A5, 0x0041, 0x00E1, 0x00C0, 0x0080, 0x00C1, 0x00C1, 0x0060, 0x0082, 0x00C6, 0x00A0, 0x0102, 0x00C2, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0061, 0x0040, 0x0040, 0x00C1, 0x00A0, 0x0060, 0x0060, 0x0062, 0x0041, 0x0081, 0x0060, 0x0020, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00A0, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A0, 0x0080,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0060, 0x0081, 0x00C1, 0x00C2, 0x00A1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x0060, 0x0060, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0081, 0x00C2, 0x00C3, 0x00C2, 0x00A2, 0x00C2, 0x00C2, 0x00C2, 0x00A2, 0x00A1, 0x00C2, 0x00C2, 0x00C2, 0x00A1, 0x00A1, 0x00A2, 0x00C2, 0x00C1, 0x00E2, 0x0102, 0x0164, 0x01A4, 0x01C5, 0x0163, 0x00C1, 0x00C1, 0x0082, 0x0084, 0x00C2, 0x0040, 0x0122, 0x00A0, 0x0080, 0x0040, 0x0040, 0x0060, 0x00A2, 0x0084, 0x00E1, 0x0060, 0x00A1, 0x0102, 0x0060, 0x0040, 0x0060, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x00A1, 0x0060, 0x00A1, 0x00C1, 0x0080, 0x0083, 0x00A2, 0x0060, 0x00A1, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0040, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0080, 0x00A0, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A0, 0x0080,
0x0020, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0081, 0x00A1, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0061, 0x0061, 0x0081, 0x0081, 0x0061, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0060, 0x0081, 0x0081, 0x0081, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00C2, 0x00C2, 0x00C2, 0x00A2, 0x0081, 0x0081, 0x00A2, 0x00C2, 0x00C2, 0x00A2, 0x00C1, 0x0102, 0x0123, 0x0143, 0x0102, 0x00E1, 0x00E1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0080, 0x0083, 0x00A6, 0x0042, 0x00E1, 0x0040, 0x0122, 0x00C1, 0x0080, 0x0040, 0x0080, 0x00C1, 0x00C5, 0x00E2, 0x00C2, 0x0123, 0x0040, 0x0040, 0x0103, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x00A1, 0x00E1, 0x00A1, 0x0040, 0x0080, 0x0083, 0x00A2, 0x0040, 0x0080, 0x00A0, 0x0060, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0081, 0x00A1, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00A1, 0x00A1, 0x00A0,
0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x0061, 0x0081, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0060, 0x0081, 0x0061, 0x0060, 0x0060, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x00A1, 0x0080, 0x0080, 0x00A1, 0x00A2, 0x00C2, 0x0081, 0x00A1, 0x0081, 0x0081, 0x00A2, 0x00A2, 0x00A2, 0x0144, 0x0123, 0x0123, 0x0144, 0x0123, 0x0102, 0x0102, 0x0102, 0x0123, 0x0143, 0x0142, 0x00E1, 0x0081, 0x0061, 0x00C1, 0x00A1, 0x0101, 0x0081, 0x00E1, 0x0080, 0x00C1, 0x00E1, 0x0080, 0x0060, 0x00A6, 0x0104, 0x00A2, 0x00A1, 0x00E1, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0081, 0x00C1, 0x0060, 0x0040, 0x0040, 0x00A0, 0x0081, 0x0081, 0x0062, 0x0080, 0x0060, 0x00A0, 0x00A1, 0x0081, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0081, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00A1, 0x00A0,
0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0060, 0x0040, 0x0040, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0061, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0081, 0x00A1, 0x00A1, 0x0081, 0x0080, 0x0080, 0x0081, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00C2, 0x00C3, 0x00C3, 0x00A2, 0x0061, 0x0081, 0x0081, 0x0081, 0x0061, 0x0081, 0x0061, 0x0081, 0x00C2, 0x00E1, 0x00E1, 0x0102, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0084, 0x0041, 0x0122, 0x00A1, 0x0102, 0x00A1, 0x00E1, 0x00C1, 0x0060, 0x0081, 0x0080, 0x0080, 0x0062, 0x00E3, 0x00A1, 0x0080, 0x00A1, 0x0102, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x00C1, 0x00A0, 0x00C1, 0x0082, 0x0081, 0x00A1, 0x00A0, 0x00A1, 0x0020, 0x0060, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0080, 0x0080, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00A1, 0x00A1, 0x0080,
0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x0081, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00A2, 0x00C3, 0x00C2, 0x0081, 0x0061, 0x0081, 0x0081, 0x00C2, 0x0122, 0x0122, 0x0143, 0x0122, 0x00E1, 0x00A1, 0x00A1, 0x00A0, 0x00A1, 0x00C1, 0x0061, 0x00A6, 0x0061, 0x00C1, 0x0121, 0x00C1, 0x00A1, 0x0102, 0x0080, 0x0061, 0x0080, 0x00C1, 0x0080, 0x0060, 0x00A1, 0x00E2, 0x00A1, 0x0101, 0x00A1, 0x0060, 0x00A1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0080, 0x0902, 0x00A0, 0x0060, 0x0080, 0x0083, 0x0061, 0x00C1, 0x0080, 0x00C1, 0x0080, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0080, 0x0060, 0x0040, 0x0040, 0x0020, 0x0040, 0x0020, 0x0060, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A0, 0x0080,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0060, 0x0060, 0x0061, 0x0081, 0x00A1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0080, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x0061, 0x0060, 0x00A1, 0x00A1, 0x0123, 0x0143, 0x0163, 0x0143, 0x0122, 0x0122, 0x0122, 0x0102, 0x0102, 0x0102, 0x00E1, 0x00A1, 0x0062, 0x0060, 0x00A1, 0x0101, 0x0963, 0x00E2, 0x0060, 0x0122, 0x0060, 0x0041, 0x00C1, 0x0060, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x0060, 0x0102, 0x00E1, 0x00C1, 0x00A1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x00A1, 0x0102, 0x00C1, 0x0020, 0x0040, 0x00C1, 0x0082, 0x0081, 0x00C1, 0x00C0, 0x0080, 0x00C1, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x0080, 0x0060, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0020, 0x0060, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0080, 0x0080, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0060, 0x00E3, 0x0164, 0x01A5, 0x01A5, 0x0206, 0x01E5, 0x01C5, 0x0164, 0x00C1, 0x00C1, 0x00C1, 0x00E1, 0x00E1, 0x00A1, 0x0084, 0x0081, 0x0081, 0x00E2, 0x0121, 0x0081, 0x0102, 0x0040, 0x0102, 0x0060, 0x00A1, 0x00E1, 0x00C1, 0x0081, 0x00A1, 0x00C2, 0x00A1, 0x00A0, 0x0040, 0x0102, 0x0060, 0x0081, 0x00A1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x00A1, 0x00E1, 0x0061, 0x0040, 0x0020, 0x00C1, 0x00A1, 0x0081, 0x0040, 0x00A1, 0x00E1, 0x00A0, 0x0081, 0x00A0, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x0060, 0x0040, 0x0060, 0x0060, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0060, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0081, 0x0060, 0x0081, 0x0081, 0x0081, 0x00A1, 0x0080, 0x0080, 0x0081, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0081, 0x00A1, 0x0081, 0x0081, 0x0080, 0x0081, 0x00C1, 0x00A1, 0x0081, 0x0061, 0x0080, 0x0081, 0x0081, 0x0040, 0x0040, 0x0061, 0x0061, 0x0060, 0x0060, 0x00E1, 0x00E1, 0x00E1, 0x0102, 0x00C1, 0x00C1, 0x00A0, 0x00A1, 0x0082, 0x0085, 0x00C3, 0x0060, 0x00C1, 0x0102, 0x00E1, 0x0062, 0x0102, 0x0080, 0x0081, 0x00E1, 0x00C1, 0x00C1, 0x0080, 0x00C1, 0x00C1, 0x00C3, 0x00A1, 0x00E1, 0x0060, 0x0040, 0x00A1, 0x00E1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0041, 0x0041, 0x00A1, 0x00C1, 0x00C1, 0x00A0, 0x0061, 0x0060, 0x00C1, 0x00E1, 0x0040, 0x0081, 0x0060, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0040, 0x0020, 0x0060, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0081, 0x0080, 0x0080, 0x0080, 0x0081, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0081, 0x0080, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0080,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x0081, 0x0080, 0x0081, 0x0081, 0x0040, 0x0040, 0x0061, 0x0061, 0x0040, 0x00C1, 0x0163, 0x09C4, 0x0A05, 0x09E5, 0x0122, 0x0102, 0x00A3, 0x0083, 0x0082, 0x0061, 0x00E1, 0x0060, 0x00C1, 0x0983, 0x00E2, 0x0061, 0x00C2, 0x00E2, 0x0040, 0x0102, 0x0040, 0x00A1, 0x00E1, 0x00E2, 0x00A1, 0x00A2, 0x0061, 0x00E2, 0x0081, 0x00A1, 0x0040, 0x00C2, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x00A1, 0x00C1, 0x00E1, 0x0080, 0x00C1, 0x0061, 0x00C1, 0x0080, 0x00C1, 0x00A1, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0060, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0060, 0x0040, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0080, 0x0081, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0081, 0x0080, 0x0080, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x0081, 0x0080,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0061, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00C1, 0x00E2, 0x00E2, 0x00A1, 0x00A1, 0x00A1, 0x0060, 0x0040, 0x0060, 0x0081, 0x0143, 0x01E5, 0x0A46, 0x01E4, 0x0183, 0x0142, 0x0102, 0x00C1, 0x0080, 0x00A1, 0x0042, 0x00A1, 0x0101, 0x0061, 0x0061, 0x0163, 0x00A1, 0x0061, 0x0060, 0x0143, 0x0040, 0x00C1, 0x0081, 0x0122, 0x0102, 0x00E1, 0x00C1, 0x00A2, 0x0060, 0x00C1, 0x0922, 0x00A1, 0x00C1, 0x0060, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x00A1, 0x0101, 0x00C1, 0x00A1, 0x00A1, 0x00C0, 0x0061, 0x0080, 0x00C1, 0x0080, 0x00A1, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x0080, 0x0060, 0x0040, 0x0060, 0x0081, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0081, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0061, 0x0081, 0x0081, 0x0081, 0x0080, 0x00A1, 0x00C1, 0x00A1, 0x00A1, 0x00E2, 0x0122, 0x0123, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0060, 0x00E2, 0x0184, 0x09E5, 0x0184, 0x0122, 0x0143, 0x00E1, 0x00E1, 0x00E2, 0x00E3, 0x0041, 0x08C4, 0x0143, 0x00E1, 0x0061, 0x0061, 0x0101, 0x00C1, 0x0040, 0x0040, 0x0123, 0x0060, 0x0080, 0x0102, 0x0081, 0x00E1, 0x00C1, 0x00A0, 0x0104, 0x00A1, 0x0040, 0x00A1, 0x0122, 0x0060, 0x00E2, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0060, 0x0102, 0x00C1, 0x00C1, 0x0081, 0x00A1, 0x00C1, 0x00A1, 0x0080, 0x00A1, 0x00C1, 0x00A1, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0020, 0x0020, 0x0061, 0x0080, 0x00A1, 0x0060, 0x0061, 0x0061, 0x0081, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x0081, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00E2, 0x0123, 0x0123, 0x00C1, 0x00C1, 0x00A1, 0x0102, 0x01A4, 0x0143, 0x0183, 0x01A3, 0x0183, 0x0142, 0x0184, 0x0143, 0x00A1, 0x0905, 0x0040, 0x0082, 0x0143, 0x0101, 0x0060, 0x0060, 0x00E1, 0x0901, 0x0040, 0x0060, 0x0102, 0x00C1, 0x00E1, 0x0060, 0x0101, 0x0080, 0x00A0, 0x00E1, 0x00A4, 0x00A0, 0x00C0, 0x0040, 0x00A1, 0x00E2, 0x0040, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0020, 0x0081, 0x0061, 0x00E1, 0x0060, 0x00C1, 0x00C1, 0x00A1, 0x0082, 0x00A1, 0x0901, 0x0080, 0x00C1, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0061, 0x0081, 0x0081, 0x0060, 0x0061, 0x0061, 0x0061, 0x0081, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040, 0x0041, 0x0040, 0x0061, 0x0081, 0x0061, 0x0060, 0x0081, 0x00A1, 0x00A1, 0x00C1, 0x00C1, 0x00A1, 0x0061, 0x0082, 0x00A2, 0x00A2, 0x00A2, 0x00C2, 0x00E2, 0x00E2, 0x00A1, 0x0081, 0x0081, 0x0143, 0x0205, 0x0183, 0x00C1, 0x0184, 0x01C5, 0x0143, 0x00C1, 0x00A4, 0x00A1, 0x0040, 0x0143, 0x0163, 0x0102, 0x0060, 0x0040, 0x0102, 0x0080, 0x00A1, 0x0040, 0x0081, 0x0102, 0x0040, 0x0102, 0x0060, 0x00A1, 0x00A1, 0x00E1, 0x00A3, 0x00A0, 0x0101, 0x00C1, 0x0040, 0x0060, 0x0102, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040, 0x00C1, 0x0060, 0x00C1, 0x00A1, 0x00A1, 0x00C1, 0x00E3, 0x0101, 0x00A1, 0x00C1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0081, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0061, 0x0041, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0080, 0x00A1, 0x00A2, 0x0082, 0x0062, 0x0062, 0x0061, 0x0082, 0x0104, 0x0105, 0x00C3, 0x0104, 0x0164, 0x0184, 0x0123, 0x01A4, 0x0184, 0x00E2, 0x0143, 0x09C5, 0x0143, 0x00A0, 0x0060, 0x0163, 0x01A4, 0x0102, 0x0060, 0x0040, 0x0061, 0x0040, 0x0143, 0x0040, 0x0020, 0x00E2, 0x0081, 0x0060, 0x00C1, 0x0060, 0x00E1, 0x00C1, 0x08C4, 0x00C1, 0x00E1, 0x0060, 0x0102, 0x0060, 0x0060, 0x00C2, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0081, 0x00E1, 0x0102, 0x0081, 0x00C1, 0x0184, 0x0163, 0x00A1, 0x00E2, 0x0081, 0x0061, 0x0041, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0041, 0x0040, 0x0040, 0x0061, 0x0081, 0x0061, 0x0061, 0x0060, 0x0040, 0x0060, 0x0081, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00C1, 0x00C2, 0x00E2, 0x00C1, 0x00C1, 0x0081, 0x0080, 0x0081, 0x0081, 0x0061, 0x0082, 0x00A2, 0x0081, 0x0061, 0x0061, 0x0061, 0x0082, 0x00C2, 0x00E4, 0x00C5, 0x0085, 0x00E3, 0x0123, 0x01A5, 0x0184, 0x00E1, 0x01E5, 0x0267, 0x0205, 0x00E1, 0x00C1, 0x0040, 0x01A4, 0x01A3, 0x0101, 0x00C1, 0x0040, 0x0040, 0x0020, 0x0103, 0x00A0, 0x0020, 0x0040, 0x0040, 0x0102, 0x0081, 0x00C1, 0x0943, 0x00A0, 0x0104, 0x0102, 0x00E1, 0x0080, 0x00A1, 0x0122, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0061, 0x0102, 0x00C1, 0x00C1, 0x00A1, 0x0163, 0x09A3, 0x00C1, 0x0060, 0x0102, 0x0061, 0x0041, 0x0041, 0x0040, 0x0040, 0x0040, 0x0041, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0061, 0x0081, 0x0060, 0x0060, 0x0081, 0x0060, 0x0040, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x0081, 0x0061, 0x0061, 0x0081, 0x0081, 0x0060, 0x0060, 0x0060, 0x0061, 0x0060, 0x0060, 0x0081, 0x0062, 0x0064, 0x0064, 0x0041, 0x0144, 0x01E7, 0x0164, 0x0081, 0x01E5, 0x0246, 0x01E5, 0x0163, 0x0143, 0x00C1, 0x0081, 0x01E4, 0x0183, 0x0122, 0x00E1, 0x00A0, 0x0040, 0x0020, 0x0040, 0x00A1, 0x0040, 0x0040, 0x0061, 0x00A1, 0x0040, 0x0963, 0x0102, 0x00E1, 0x01A4, 0x0163, 0x0060, 0x0143, 0x0040, 0x00A1, 0x0102, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0122, 0x0040, 0x00E1, 0x00A1, 0x0183, 0x0162, 0x0122, 0x0080, 0x00A1, 0x0061, 0x0041, 0x0041, 0x0040, 0x0040, 0x0041, 0x0041, 0x0020, 0x0020, 0x0020, 0x0020, 0x0041, 0x0080, 0x0061, 0x0040, 0x0061, 0x0081, 0x0060, 0x0060, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0060, 0x0040, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0060, 0x0081, 0x0084, 0x0064, 0x0043, 0x0021, 0x00A2, 0x00E3, 0x0103, 0x0061, 0x01A4, 0x0226, 0x0225, 0x0205, 0x0183, 0x01A4, 0x00A1, 0x00E1, 0x01A3, 0x01A3, 0x01E4, 0x0122, 0x00C1, 0x0080, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x00C2, 0x0963, 0x0102, 0x0102, 0x01E4, 0x01E4, 0x0080, 0x00E2, 0x0102, 0x0040, 0x00A1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x00A1, 0x00C1, 0x0020, 0x0102, 0x00E2, 0x0163, 0x0142, 0x0121, 0x00E1, 0x00C1, 0x0041, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0041, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0081, 0x0060, 0x0040, 0x0061, 0x0061, 0x0060, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0040, 0x0040, 0x0020, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00C2, 0x00E2, 0x00C2, 0x00C1, 0x00C1, 0x0081, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0081, 0x0081, 0x0081, 0x0060, 0x0081, 0x0081, 0x0082, 0x0064, 0x0064, 0x0042, 0x0042, 0x0041, 0x0061, 0x0081, 0x0061, 0x00C2, 0x0226, 0x0AA7, 0x0267, 0x0205, 0x01C4, 0x0163, 0x0060, 0x00E1, 0x0142, 0x09C4, 0x01E4, 0x0122, 0x0102, 0x00C1, 0x0080, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0061, 0x0123, 0x00E2, 0x0101, 0x0163, 0x01E4, 0x01A3, 0x00A0, 0x0060, 0x0143, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0081, 0x0040, 0x0040, 0x00E1, 0x0101, 0x0163, 0x0142, 0x0122, 0x0143, 0x0102, 0x0061, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x00A1, 0x0060, 0x0040, 0x0061, 0x0061, 0x0060, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0061, 0x0061, 0x0060, 0x0061, 0x0081, 0x00A1, 0x00C1, 0x00C2, 0x00C2, 0x00C2, 0x00A2, 0x0061, 0x0081, 0x0081, 0x0060, 0x0060, 0x0081, 0x00A1, 0x0060, 0x0060, 0x0060, 0x0081, 0x0081, 0x00C4, 0x0065, 0x0043, 0x0042, 0x0041, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x01A4, 0x0225, 0x0AC8, 0x0266, 0x0183, 0x0163, 0x0102, 0x0040, 0x00A1, 0x0142, 0x09E5, 0x01A4, 0x09A4, 0x0143, 0x0080, 0x00C1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x00E3, 0x0123, 0x0102, 0x01A3, 0x01C3, 0x0142, 0x0962, 0x0060, 0x00E2, 0x00A1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0061, 0x0102, 0x0183, 0x0143, 0x0983, 0x00E4, 0x00C1, 0x00A1, 0x0041, 0x0020, 0x0040, 0x0061, 0x0061, 0x0061, 0x0061, 0x0041, 0x0041, 0x0020, 0x0041, 0x0081, 0x0040, 0x0040, 0x0061, 0x0040, 0x0041, 0x0060, 0x0040, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00A1, 0x00C2, 0x00E3, 0x00A1, 0x0081, 0x00C1, 0x00A1, 0x0060, 0x0081, 0x00E2, 0x00C1, 0x0060, 0x0040, 0x0061, 0x0081, 0x00A4, 0x0064, 0x0042, 0x0042, 0x0063, 0x0041, 0x0060, 0x00A2, 0x08A2, 0x0082, 0x00A1, 0x12C8, 0x0AE9, 0x0267, 0x01C4, 0x01A5, 0x0143, 0x00E2, 0x0040, 0x0060, 0x00E1, 0x01E5, 0x0A26, 0x01C4, 0x0164, 0x00E1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0080, 0x09C4, 0x09E4, 0x01A3, 0x0101, 0x11E4, 0x00E1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0060, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0984, 0x09C4, 0x0183, 0x0984, 0x0104, 0x00E1, 0x0061, 0x0040, 0x0040, 0x0041, 0x0061, 0x0061, 0x0041, 0x0061, 0x0061, 0x0041, 0x0040, 0x0020, 0x0041, 0x0020, 0x0040, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0081, 0x00C1, 0x00E2, 0x00E2, 0x00C1, 0x00C1, 0x00C2, 0x00C2, 0x00A1, 0x00C1, 0x00C1, 0x0080, 0x0060, 0x00A1, 0x00C1, 0x0081, 0x0060, 0x0081, 0x00A1, 0x00A4, 0x0064, 0x0041, 0x0041, 0x0042, 0x0041, 0x0060, 0x0060, 0x00A1, 0x08C3, 0x0081, 0x0184, 0x0A67, 0x0246, 0x0226, 0x0184, 0x0A46, 0x0164, 0x00A1, 0x0040, 0x0040, 0x0040, 0x0184, 0x0A26, 0x01A4, 0x09A4, 0x0122, 0x0040, 0x0040, 0x0040, 0x0061, 0x0041, 0x0040, 0x0040, 0x0040, 0x0142, 0x0A05, 0x0A67, 0x0183, 0x0183, 0x09A4, 0x0101, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0144, 0x01C4, 0x09A4, 0x0963, 0x00C1, 0x0902, 0x00A1, 0x0040, 0x0040, 0x0041, 0x0061, 0x0061, 0x0041, 0x0041, 0x0041, 0x0041, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0061, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00E2, 0x0122, 0x0102, 0x00E1, 0x00E2, 0x00C1, 0x0080, 0x00C1, 0x0102, 0x00E2, 0x00A1, 0x0081, 0x00A1, 0x0081, 0x0040, 0x0040, 0x0060, 0x0084, 0x0063, 0x0061, 0x0062, 0x0042, 0x0040, 0x0040, 0x0061, 0x0041, 0x0040, 0x0060, 0x0060, 0x0164, 0x0143, 0x0226, 0x0205, 0x01C4, 0x0184, 0x0103, 0x00A1, 0x0040, 0x0020, 0x0020, 0x0081, 0x0184, 0x0163, 0x0102, 0x0102, 0x0040, 0x0041, 0x0061, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0102, 0x1246, 0x0A46, 0x09A4, 0x09E5, 0x0142, 0x00E1, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0102, 0x0163, 0x0983, 0x0101, 0x00A1, 0x0902, 0x0061, 0x0040, 0x0040, 0x0041, 0x0041, 0x0042, 0x0041, 0x0041, 0x0041, 0x0041, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0020, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0041, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00E2, 0x00E2, 0x00C1, 0x00C1, 0x00C1, 0x00C1, 0x0080, 0x0080, 0x00C1, 0x0102, 0x00C1, 0x00C1, 0x00A1, 0x00A1, 0x0060, 0x0060, 0x0042, 0x0042, 0x0061, 0x0062, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x01C4, 0x0184, 0x01E5, 0x01A4, 0x00A1, 0x0081, 0x0060, 0x0040, 0x0020, 0x0020, 0x0020, 0x00A1, 0x00A1, 0x00C1, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0102, 0x01C4, 0x01E5, 0x09E5, 0x09C4, 0x00E1, 0x00A0, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x00C1, 0x0102, 0x00E1, 0x0963, 0x0061, 0x00A1, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0021, 0x0041, 0x0041, 0x0041, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0041, 0x0041, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x00C1, 0x00C1, 0x00C1, 0x00A1, 0x0080, 0x0080, 0x00A1, 0x0080, 0x00A1, 0x00C1, 0x00C1, 0x0082, 0x0021, 0x0040, 0x0082, 0x0042, 0x0040, 0x0040, 0x0041, 0x0082, 0x0060, 0x0040, 0x0081, 0x0060, 0x0060, 0x0080, 0x0163, 0x01C5, 0x0184, 0x0143, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0060, 0x0040, 0x0143, 0x09A4, 0x0163, 0x0983, 0x0963, 0x00E1, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0963, 0x00A1, 0x0922, 0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0020, 0x0020, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00A1, 0x00C1, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0061, 0x0062, 0x0062, 0x0082, 0x0062, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0081, 0x0060, 0x0040, 0x0080, 0x0060, 0x0060, 0x0080, 0x00A1, 0x01E5, 0x00C1, 0x00A1, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x0081, 0x0061, 0x0061, 0x0061, 0x0060, 0x0081, 0x09A4, 0x1225, 0x00C1, 0x0122, 0x00E1, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0061, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0041, 0x0061, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0922, 0x0061, 0x0081, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0040, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x00A1, 0x0103, 0x0123, 0x00E2, 0x00C1, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0082, 0x0082, 0x0061, 0x0042, 0x00A3, 0x0105, 0x0062, 0x0020, 0x0040, 0x0060, 0x0060, 0x0040, 0x0081, 0x0060, 0x0040, 0x0060, 0x0080, 0x0060, 0x0080, 0x00C1, 0x00A1, 0x0080, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0081, 0x0081, 0x0040, 0x0061, 0x0081, 0x0060, 0x0040, 0x0122, 0x0102, 0x0060, 0x0080, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0041, 0x0041, 0x0040, 0x0061, 0x0061, 0x0040, 0x0020, 0x0020, 0x0020, 0x0041, 0x0041, 0x0061, 0x0041, 0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x00E2, 0x00E2, 0x00C1, 0x00E2, 0x00E1, 0x00A1, 0x0081, 0x0081, 0x0061, 0x0061, 0x0081, 0x0080, 0x0081, 0x00A1, 0x0080, 0x0080, 0x00A1, 0x0062, 0x0061, 0x0061, 0x0041, 0x0020, 0x0020, 0x0020, 0x0040, 0x0080, 0x0060, 0x0060, 0x0080, 0x0060, 0x0080, 0x00C1, 0x0080, 0x0080, 0x00A0, 0x00A1, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0061, 0x0081, 0x0061, 0x0040, 0x0061, 0x0081, 0x0060, 0x0040, 0x0060, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0041, 0x0041, 0x0040, 0x0041, 0x0061, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0061, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x00A1, 0x00C2, 0x00E2, 0x00C2, 0x00C1, 0x0081, 0x0060, 0x0081, 0x0081, 0x0080, 0x0080, 0x0060, 0x0060, 0x0081, 0x0080, 0x0080, 0x0081, 0x0061, 0x0041, 0x0021, 0x0020, 0x0020, 0x0041, 0x0061, 0x0060, 0x0080, 0x00A1, 0x0080, 0x00A0, 0x0080, 0x0080, 0x00A0, 0x00C1, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0061, 0x0060, 0x0060, 0x0081, 0x0061, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x0081, 0x0060, 0x0040, 0x0061, 0x0061, 0x0040, 0x0061, 0x0060, 0x0040, 0x0061, 0x0061, 0x0041, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0061, 0x0061, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x0081, 0x00E2, 0x0123, 0x0143, 0x00E2, 0x00C2, 0x0081, 0x0081, 0x00A1, 0x0081, 0x00A1, 0x00C1, 0x00A0, 0x0081, 0x00A1, 0x0060, 0x0081, 0x00C2, 0x0081, 0x0040, 0x0042, 0x0041, 0x0041, 0x0040, 0x00A2, 0x00A1, 0x0060, 0x00A0, 0x00A1, 0x0080, 0x00A0, 0x00A1, 0x0080, 0x00C0, 0x00E1, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0060, 0x0060, 0x0060, 0x0060, 0x00A2, 0x0081, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0060, 0x0040, 0x0040, 0x0060, 0x0040, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0041, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0041, 0x0041, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0040, 0x0041, 0x0041, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0061, 0x0081, 0x0103, 0x01A4, 0x0205, 0x01A4, 0x0143, 0x00A1, 0x00E2, 0x00E1, 0x00A1, 0x0080, 0x00E1, 0x00C1, 0x00E1, 0x00E1, 0x00A1, 0x0082, 0x00C6, 0x00A6, 0x0041, 0x0021, 0x0021, 0x0020, 0x0020, 0x0040, 0x0082, 0x00A1, 0x0080, 0x00A0, 0x00A1, 0x00A0, 0x00C0, 0x00C1, 0x0080, 0x00A0, 0x00C0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x0040, 0x0060, 0x0060, 0x0061, 0x0081, 0x0060, 0x0040, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0060, 0x0040, 0x0040, 0x0061, 0x0060, 0x0061, 0x0081, 0x0081, 0x0081, 0x0060, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0061, 0x0040, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0040, 0x0040, 0x0041, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0061, 0x0041, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x00A1, 0x0164, 0x01C4, 0x01C5, 0x0164, 0x00E2, 0x00C2, 0x00C2, 0x0081, 0x00C2, 0x0102, 0x0102, 0x00C1, 0x00A1, 0x0080, 0x0080, 0x0061, 0x0084, 0x0064, 0x0021, 0x0021, 0x0020, 0x0040, 0x0040, 0x0040, 0x0041, 0x0081, 0x00A0, 0x00C0, 0x00A1, 0x00A0, 0x00C0, 0x00C1, 0x00A1, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0060, 0x0080, 0x0060, 0x0061, 0x0061, 0x0080, 0x0080, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0060, 0x0060, 0x0061, 0x0081, 0x0082, 0x0081, 0x0041, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0061, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0061, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x00C2, 0x0102, 0x0102, 0x0102, 0x00C2, 0x0081, 0x0061, 0x0061, 0x0081, 0x00A1, 0x00A1, 0x00A1, 0x00A1, 0x0080, 0x0060, 0x0040, 0x0041, 0x0062, 0x0040, 0x0042, 0x0020, 0x0040, 0x0060, 0x0060, 0x0040, 0x0041, 0x0061, 0x00A0, 0x00C0, 0x00A1, 0x00A0, 0x00C0, 0x00C0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x00A1, 0x0080, 0x0060, 0x0061, 0x0061, 0x0060, 0x0081, 0x0080, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0060, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0041, 0x0040, 0x0041, 0x0061, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0041, 0x0021, 0x0020, 0x0040, 0x0020, 0x0040, 0x0061, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x00A1, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0062, 0x00A5, 0x0043, 0x0020, 0x0040, 0x0040, 0x0040, 0x0060, 0x0040, 0x0061, 0x0060, 0x0080, 0x00C0, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0081, 0x00A1, 0x0080, 0x0060, 0x0040, 0x0061, 0x0060, 0x0060, 0x0081, 0x0081, 0x0081, 0x0060, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0060, 0x0061, 0x0061, 0x0061, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0040, 0x0040, 0x0041, 0x0061, 0x0061, 0x0081, 0x0061, 0x0040, 0x0040, 0x0061, 0x0061, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0041, 0x0040, 0x0020, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x00A1, 0x00A1, 0x00C1, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0084, 0x0021, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0040, 0x0060, 0x00A0, 0x0080, 0x00A0, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0081, 0x00A1, 0x0060, 0x0040, 0x0040, 0x0060, 0x0081, 0x0060, 0x0060, 0x0060, 0x0081, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0081, 0x0082, 0x0061, 0x0060, 0x0060, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0041, 0x0041, 0x0041, 0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0081, 0x0061, 0x0041, 0x0041, 0x0061, 0x0061, 0x0060, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020,
0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0061, 0x0061, 0x0081, 0x00C1, 0x00C1, 0x00A1, 0x0060, 0x0060, 0x0060, 0x0081, 0x0040, 0x0040, 0x0060, 0x0080, 0x0040, 0x0020, 0x0040, 0x0060, 0x0080, 0x0060, 0x0040, 0x0040, 0x00A0, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0081, 0x0060, 0x0081, 0x0081, 0x0060, 0x0081, 0x0060, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0060, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0061, 0x0041, 0x0061, 0x0061, 0x0041, 0x0040, 0x0041, 0x0041, 0x0041, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0041, 0x0041, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020,
0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0081, 0x0061, 0x0060, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0040, 0x0060, 0x0080, 0x0060, 0x0060, 0x0040, 0x0060, 0x0080, 0x0080, 0x0061, 0x0061, 0x0060, 0x00A1, 0x00A0, 0x00A0, 0x00A0, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x00A1, 0x0081, 0x0060, 0x0060, 0x0061, 0x0060, 0x0060, 0x00A1, 0x0081, 0x0060, 0x0061, 0x0040, 0x0040, 0x0040, 0x0061, 0x0060, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0041, 0x0061, 0x0081, 0x0060, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x0041, 0x0041, 0x0061, 0x0081, 0x0081, 0x0061, 0x0041, 0x0041, 0x0061, 0x0040, 0x0040, 0x0041, 0x0061, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0020, 0x0000, 0x0020, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0061, 0x0041, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020,
0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0040, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x0080, 0x0040, 0x0060, 0x0080, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0041, 0x0061, 0x00A1, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x00A1, 0x00A1, 0x0060, 0x0081, 0x0081, 0x0081, 0x0060, 0x0060, 0x0081, 0x00C1, 0x0081, 0x0040, 0x0040, 0x0020, 0x0040, 0x0060, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0061, 0x0061, 0x0081, 0x0060, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0041, 0x0041, 0x0041, 0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0041, 0x0041, 0x0040, 0x0061, 0x0041, 0x0040, 0x0041, 0x0041, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0041, 0x0041, 0x0061, 0x0041, 0x0040, 0x0041, 0x0061, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020,
0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0061, 0x00A1, 0x00A1, 0x0060, 0x0061, 0x0040, 0x0080, 0x0040, 0x0060, 0x0080, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0081, 0x0080, 0x0081, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0081, 0x00C1, 0x0080, 0x0080, 0x00E2, 0x0081, 0x0081, 0x0060, 0x0081, 0x0060, 0x0060, 0x00A1, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0060, 0x0060, 0x0061, 0x0081, 0x0081, 0x0061, 0x0040, 0x0040, 0x0020, 0x0040, 0x0041, 0x0041, 0x0041, 0x0020, 0x0020, 0x0040, 0x0041, 0x0061, 0x0061, 0x0041, 0x0041, 0x0041, 0x0040, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0040, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0020, 0x0000, 0x0020,
0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x00C1, 0x00C1, 0x0080, 0x0060, 0x0060, 0x0061, 0x0040, 0x00A1, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x00A1, 0x0080, 0x0060, 0x0040, 0x0040, 0x0081, 0x0060, 0x00A1, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0080, 0x0060, 0x00A1, 0x00E2, 0x00E2, 0x0080, 0x0061, 0x0061, 0x0060, 0x0061, 0x0040, 0x0061, 0x0081, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0081, 0x0061, 0x0060, 0x0061, 0x0060, 0x0081, 0x00A1, 0x0081, 0x0081, 0x0061, 0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0020, 0x0020, 0x0040, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0041, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0041, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x00C2, 0x0122, 0x00A1, 0x0080, 0x00A0, 0x0081, 0x0060, 0x0040, 0x0080, 0x0040, 0x0040, 0x0060, 0x0080, 0x0060, 0x0080, 0x0080, 0x0060, 0x0020, 0x0060, 0x00A0, 0x0060, 0x0081, 0x0060, 0x0080, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x00A1, 0x00E2, 0x00E2, 0x00A1, 0x00C1, 0x00A2, 0x0080, 0x0060, 0x0081, 0x0040, 0x0040, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0060, 0x0061, 0x0061, 0x0081, 0x0081, 0x0061, 0x0081, 0x0081, 0x0061, 0x0060, 0x0081, 0x0081, 0x0081, 0x0061, 0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0020, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0041, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0040, 0x0041, 0x0040, 0x0041, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0020, 0x0020,
0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0061, 0x0081, 0x00E1, 0x00E1, 0x00A1, 0x0081, 0x0041, 0x00A1, 0x0040, 0x0081, 0x0080, 0x0060, 0x0060, 0x0040, 0x0060, 0x0080, 0x0081, 0x0040, 0x0061, 0x0080, 0x00A1, 0x0080, 0x0040, 0x0060, 0x00A1, 0x0060, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x00E2, 0x00E2, 0x0080, 0x00C1, 0x00C2, 0x00E3, 0x0061, 0x0081, 0x0080, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0081, 0x0061, 0x0060, 0x0060, 0x0060, 0x0081, 0x0061, 0x0061, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0041, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0041, 0x0041, 0x0040, 0x0061, 0x0041, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0041, 0x0041,
0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0081, 0x00E2, 0x00E1, 0x00C1, 0x0081, 0x0081, 0x0060, 0x00C1, 0x0060, 0x0060, 0x0080, 0x0081, 0x0040, 0x0060, 0x0080, 0x00A1, 0x0060, 0x0040, 0x0081, 0x0080, 0x00C1, 0x0060, 0x0040, 0x0040, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x00C1, 0x00C1, 0x00A0, 0x00A0, 0x0102, 0x00C2, 0x0104, 0x0081, 0x0081, 0x0081, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0060, 0x0060, 0x0061, 0x0060, 0x0060, 0x0060, 0x0061, 0x0040, 0x0040, 0x0061, 0x0060, 0x0060, 0x0061, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0041, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0000, 0x0020, 0x0020, 0x0041, 0x0061, 0x0061, 0x0040, 0x0041, 0x0061, 0x0041, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0020, 0x0040, 0x0061,
0x0040, 0x0040, 0x0041, 0x0040, 0x0041, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x00C2, 0x00C2, 0x00A1, 0x00C1, 0x00A1, 0x0062, 0x00C2, 0x0060, 0x00E1, 0x0080, 0x0081, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x00A1, 0x0080, 0x0040, 0x0060, 0x00C1, 0x00A1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x00C1, 0x00C1, 0x0081, 0x00E3, 0x0081, 0x0060, 0x00A1, 0x0081, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0040, 0x0060, 0x0061, 0x0061, 0x0061, 0x0060, 0x0081, 0x0060, 0x0040, 0x0060, 0x0061, 0x0040, 0x0020, 0x0020, 0x0020, 0x0041, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0041, 0x0020, 0x0020, 0x0041, 0x0020,
0x0040, 0x0041, 0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0041, 0x0081, 0x0103, 0x00E2, 0x0081, 0x0061, 0x0082, 0x0080, 0x0080, 0x00C1, 0x0040, 0x00C1, 0x0040, 0x0040, 0x0040, 0x0040, 0x00A1, 0x0102, 0x0060, 0x0081, 0x0060, 0x00A1, 0x00A1, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00A1, 0x0080, 0x0061, 0x00C2, 0x0060, 0x0040, 0x0081, 0x00C1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0061, 0x0061, 0x0081, 0x0081, 0x0060, 0x0040, 0x0060, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0041, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0041, 0x0041, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0041, 0x0061, 0x0041, 0x0040, 0x0020,
0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x00A1, 0x0102, 0x00E2, 0x00E1, 0x00C1, 0x0081, 0x0081, 0x0060, 0x00A1, 0x00C2, 0x0040, 0x00A1, 0x00A1, 0x0040, 0x0040, 0x0060, 0x00E2, 0x0080, 0x0080, 0x00A1, 0x00A0, 0x0060, 0x00C1, 0x00A1, 0x0081, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00A1, 0x0080, 0x0080, 0x0061, 0x0081, 0x0080, 0x0040, 0x0060, 0x00C1, 0x0061, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0061, 0x00A1, 0x00A1, 0x0060, 0x0060, 0x0061, 0x0081, 0x0081, 0x0061, 0x0081, 0x0081, 0x0061, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0060, 0x0061, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0041, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040,
0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x00E3, 0x0123, 0x0122, 0x0102, 0x00A1, 0x00A1, 0x0020, 0x00A1, 0x0040, 0x00A1, 0x00E1, 0x0060, 0x0040, 0x00A1, 0x0040, 0x0040, 0x0040, 0x0080, 0x00C1, 0x0081, 0x0081, 0x00A1, 0x00C1, 0x0040, 0x0081, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00C1, 0x00C1, 0x0080, 0x0061, 0x0061, 0x0081, 0x0080, 0x0060, 0x0060, 0x0060, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0060, 0x0081, 0x00A1, 0x0061, 0x0060, 0x0060, 0x0061, 0x0081, 0x0081, 0x0061, 0x0081, 0x0081, 0x0081, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0041, 0x0041, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0041, 0x0061, 0x0061, 0x0061, 0x0041, 0x0020, 0x0040, 0x0041, 0x0040, 0x0020, 0x0020,
0x0040, 0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x00A1, 0x00C3, 0x00E2, 0x00C1, 0x00A1, 0x00C2, 0x00A1, 0x0020, 0x00C3, 0x0060, 0x0060, 0x00E2, 0x0080, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x00E2, 0x0143, 0x0081, 0x00C1, 0x0080, 0x00E2, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00C0, 0x00C1, 0x00C1, 0x0080, 0x0060, 0x0081, 0x0060, 0x0081, 0x00A1, 0x0060, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0060, 0x0061, 0x0061, 0x0061, 0x0060, 0x0061, 0x0081, 0x00A1, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0081, 0x0060, 0x0040, 0x0020, 0x0020, 0x0020, 0x0040, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0000, 0x0020, 0x0020, 0x0000, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0020, 0x0041, 0x0082, 0x0081, 0x0040, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x0041, 0x0020, 0x0020, 0x0020,
0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x00E2, 0x0123, 0x0102, 0x0123, 0x0163, 0x00E2, 0x00C2, 0x0060, 0x0060, 0x00E2, 0x0060, 0x0081, 0x00E2, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x00A1, 0x0143, 0x00A1, 0x0122, 0x00C1, 0x00E2, 0x0081, 0x00A1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00C1, 0x00A0, 0x0080, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x00A1, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x00A1, 0x00A1, 0x00A2, 0x00C2, 0x0081, 0x0081, 0x0081, 0x0081, 0x0081, 0x0040, 0x0020, 0x0020, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0041, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0061, 0x0081, 0x0081, 0x0060, 0x0040, 0x0020, 0x0020, 0x0040, 0x0041, 0x0040, 0x0020,
0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0081, 0x0103, 0x0143, 0x0163, 0x0142, 0x0124, 0x0081, 0x0081, 0x0060, 0x0102, 0x0040, 0x00A1, 0x00A1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x00A2, 0x00A1, 0x0060, 0x0143, 0x0101, 0x0123, 0x0080, 0x0081, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A0, 0x00A0, 0x00A0, 0x0081, 0x00A1, 0x0081, 0x0081, 0x0080, 0x00A1, 0x0081, 0x00C1, 0x0061, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0081, 0x00C2, 0x00A1, 0x0081, 0x00A2, 0x0061, 0x0060, 0x0060, 0x0040, 0x0081, 0x0061, 0x0040, 0x0020, 0x0040, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0040, 0x0061,
0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x00A2, 0x0143, 0x01E5, 0x0163, 0x0101, 0x0122, 0x0143, 0x00C2, 0x00C1, 0x00A1, 0x0061, 0x00E2, 0x0040, 0x00A2, 0x00A1, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x00A1, 0x0163, 0x0163, 0x0143, 0x00C2, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x0080, 0x0080, 0x00A1, 0x00C1, 0x00A1, 0x0080, 0x0060, 0x0061, 0x0081, 0x0081, 0x0081, 0x0081, 0x00A1, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x00A1, 0x00C2, 0x0081, 0x0061, 0x0081, 0x0081, 0x0060, 0x0061, 0x0040, 0x0040, 0x0061, 0x0040, 0x0020, 0x0040, 0x0061, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0060, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020, 0x0040, 0x0020, 0x0020, 0x0020, 0x0041, 0x0020, 0x0020, 0x0000, 0x0000, 0x0020, 0x0020, 0x0000, 0x0020, 0x0020, 0x0040, 0x0040, 0x0020, 0x0020,
0x0040, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0061, 0x0061, 0x0061, 0x00E2, 0x0184, 0x01A4, 0x0122, 0x0102, 0x0123, 0x00C2, 0x0081, 0x0102, 0x0061, 0x0081, 0x00A2, 0x0040, 0x0061, 0x00C2, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0143, 0x0163, 0x0122, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0040, 0x0040, 0x0040, 0x0060, 0x0060, 0x0060, 0x0060, 0x0060, 0x0080, 0x0080, 0x00A0, 0x00E1, 0x00C1, 0x0080, 0x0080, 0x0060, 0x0041, 0x0081, 0x0060, 0x00A1, 0x0081, 0x0081, 0x0081, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x00A1, 0x00A1, 0x0081, 0x0061, 0x0061, 0x0061, 0x0060, 0x0060, 0x0060, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0040, 0x0041, 0x0061, 0x0061, 0x0061, 0x0061, 0x0040, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0040, 0x0020, 0x0041, 0x0040, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0020, 0x0041, 0x0040, 0x0020, 0x0020, 0x0020
};
| [
"matthew.bellafaire@gmail.com"
] | matthew.bellafaire@gmail.com |
42827b7a5c1654ff67390daa37ccd4c58623565c | cd22f1be7218cc0c392cf57fb6b11557f12fefe1 | /Sequential_CNN/sgd_optimizer.h | 6f56701edc7866576d1323717170d2c9a5af6dc0 | [] | no_license | Hsain-98/Parallel-Convolutional-Networks | a5e67520439ffa6ac8ab6fdc34b2a0f0f6641a33 | 6c5f3e0b4c606fd479cc16e39370428bfd5a51b2 | refs/heads/master | 2021-09-15T11:34:42.443841 | 2018-05-31T18:46:21 | 2018-05-31T18:46:21 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 414 | h | #ifndef __SGD_H_INCLUDED__
#define __SGD_H_INCLUDED__
#include<math.h>
#include "optimizer.h"
using namespace std;
template <class T>
class SGDOptimizer: public Optimizer<T> {
public:
void updateWeight(T& weight, Gradient<T> grad, float learningRate, int batchSize) {
weight = weight - learningRate * grad.value / float(batchSize);
}
void updateGradient(Gradient<T>& grad) {
(void)0;
}
};
#endif | [
"varunsyal1994@gmail.com"
] | varunsyal1994@gmail.com |
44efecdaf23ec9dbd65bf05fad57bbac2e0f5529 | ca6c10c6f861404b2e15010a00fd2a327809d899 | /Graphs/toposort.cpp | 9aab96e7d6b5e7bb8da7bf053846cb6697b4a61d | [] | no_license | aniketakgec/CommonAlgos | b1fab1e1e525445032bd408e4df7f3bd50d488d6 | 0c47b745e15470a67c6f6fa0699d4bc17717f01a | refs/heads/master | 2022-12-05T10:13:35.663360 | 2020-08-21T09:00:56 | 2020-08-21T09:00:56 | 273,922,364 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 921 | cpp | #include<bits/stdc++.h>
using namespace std;
#define ll long long int
#define fastio ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);
vector<ll> adj[10001];
int in[10001];
vector<ll> res;
void toposort(int n) // based on kahn algorithm
{
queue<ll> q;
for (int i = 1; i <=n; ++i)
{
if(in[i]==0)
q.push(i);
}
//function like bfs
while(!q.empty())
{
ll cur_node=q.front();
res.push_back(cur_node);
q.pop();
for(ll forwardNeighbour:adj[cur_node])
{
in[forwardNeighbour]--;
if(in[forwardNeighbour]==0)
q.push(forwardNeighbour);
}
}
cout<<"TOPOSORT :"<<endl;
for(auto it:res)
cout<<it<<" ";
}
int main()
{
#ifndef ONLINE_JUDGE
freopen("input.txt","r",stdin);
freopen("output.txt","w",stdout);
#endif
ll n,m,u,v;
cin>>n>>m;
memset(in,0,sizeof(in));
while(m--)
{
cin>>u>>v;
adj[u].push_back(v);
in[v]++;
}
toposort(n);
return 0;
}
| [
"aniketpandey353@gmail.com"
] | aniketpandey353@gmail.com |
4cbf3ff387d0f7b2f0557aab00b299c3f5a57563 | edc19019ad9957723bc61b8ccf3d049fc11de3ce | /day5.cpp | d840447773ac3c97565c1b25eed2392c2306f9c6 | [] | no_license | phmongeau/advent-of-code-2019 | 0e56cae135d1f178bdabb1b128669cdb6c87b3ee | a82405bf00c19932fd041d54924bf9e46331bb7f | refs/heads/master | 2021-07-25T17:42:39.671003 | 2019-12-18T04:55:39 | 2019-12-18T04:56:47 | 226,598,065 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 6,410 | cpp | #include <iostream>
#include <cmath>
#include <climits>
#include <cstring>
int main()
{
int INPUT = 5;
// int OUTPUT = 0;
int start_memory[] = {
// 3,9,8,9,10,9,4,9,99,-1,8
// 3,9,7,9,10,9,4,9,99,-1,8,
// 3,3,1108,-1,8,3,4,3,99,
// 3,3,1107,-1,8,3,4,3,99
// 3,12,6,12,15,1,13,14,13,4,13,99,-1,0,1,9,
// 3,3,1105,-1,9,1101,0,0,12,4,12,99,1
// 3,21,1008,21,8,20,1005,20,22,107,8,21,20,1006,20,31,
// 1106,0,36,98,0,0,1002,21,125,20,4,20,1105,1,46,104,
// 999,1105,1,46,1101,1000,1,20,4,20,1105,1,46,98,99
// 3,0,4,0,99,
// 1002,4,3,4,33,
// 1101,100,-1,4,0,
3,225,1,225,6,6,1100,1,238,225,104,0,2,171,209,224,1001,224,-1040,224,4,224,102,8,223,223,1001,224,4,224,1,223,224,223,102,65,102,224,101,-3575,224,224,4,224,102,8,223,223,101,2,224,224,1,223,224,223,1102,9,82,224,1001,224,-738,224,4,224,102,8,223,223,1001,224,2,224,1,223,224,223,1101,52,13,224,1001,224,-65,224,4,224,1002,223,8,223,1001,224,6,224,1,223,224,223,1102,82,55,225,1001,213,67,224,1001,224,-126,224,4,224,102,8,223,223,1001,224,7,224,1,223,224,223,1,217,202,224,1001,224,-68,224,4,224,1002,223,8,223,1001,224,1,224,1,224,223,223,1002,176,17,224,101,-595,224,224,4,224,102,8,223,223,101,2,224,224,1,224,223,223,1102,20,92,225,1102,80,35,225,101,21,205,224,1001,224,-84,224,4,224,1002,223,8,223,1001,224,1,224,1,224,223,223,1101,91,45,225,1102,63,5,225,1101,52,58,225,1102,59,63,225,1101,23,14,225,4,223,99,0,0,0,677,0,0,0,0,0,0,0,0,0,0,0,1105,0,99999,1105,227,247,1105,1,99999,1005,227,99999,1005,0,256,1105,1,99999,1106,227,99999,1106,0,265,1105,1,99999,1006,0,99999,1006,227,274,1105,1,99999,1105,1,280,1105,1,99999,1,225,225,225,1101,294,0,0,105,1,0,1105,1,99999,1106,0,300,1105,1,99999,1,225,225,225,1101,314,0,0,106,0,0,1105,1,99999,1008,677,677,224,1002,223,2,223,1006,224,329,101,1,223,223,1108,226,677,224,1002,223,2,223,1006,224,344,101,1,223,223,7,677,226,224,102,2,223,223,1006,224,359,1001,223,1,223,8,677,226,224,102,2,223,223,1005,224,374,1001,223,1,223,1107,677,226,224,102,2,223,223,1006,224,389,1001,223,1,223,1008,226,226,224,1002,223,2,223,1005,224,404,1001,223,1,223,7,226,677,224,102,2,223,223,1005,224,419,1001,223,1,223,1007,677,677,224,102,2,223,223,1006,224,434,1001,223,1,223,107,226,226,224,1002,223,2,223,1005,224,449,1001,223,1,223,1008,677,226,224,102,2,223,223,1006,224,464,1001,223,1,223,1007,677,226,224,1002,223,2,223,1005,224,479,1001,223,1,223,108,677,677,224,1002,223,2,223,1006,224,494,1001,223,1,223,108,226,226,224,1002,223,2,223,1006,224,509,101,1,223,223,8,226,677,224,102,2,223,223,1006,224,524,101,1,223,223,107,677,226,224,1002,223,2,223,1005,224,539,1001,223,1,223,8,226,226,224,102,2,223,223,1005,224,554,101,1,223,223,1108,677,226,224,102,2,223,223,1006,224,569,101,1,223,223,108,677,226,224,102,2,223,223,1006,224,584,1001,223,1,223,7,677,677,224,1002,223,2,223,1005,224,599,101,1,223,223,1007,226,226,224,102,2,223,223,1005,224,614,1001,223,1,223,1107,226,677,224,102,2,223,223,1006,224,629,101,1,223,223,1107,226,226,224,102,2,223,223,1005,224,644,1001,223,1,223,1108,677,677,224,1002,223,2,223,1005,224,659,101,1,223,223,107,677,677,224,1002,223,2,223,1006,224,674,1001,223,1,223,4,223,99,226
};
int size = (sizeof(start_memory)/sizeof(start_memory[0]));
int memory[size];
memcpy(memory, start_memory, sizeof(memory));
int *start = memory;
int mem_size = (sizeof(memory)/sizeof(int));
int *end = memory + mem_size;
// memory[1] = noun;
// memory[2] = verb;
// for(int *ptr = memory; *ptr != 99; ptr += 4)
int should_exit = 0;
for(int *ptr = memory; !should_exit; /* ptr += 4 */)
{
// std::cout << "op code: " << *ptr << std::endl;
// for(int *i = ptr; i < ptr+4; ++i)
// std::cout << *i << ", ";
// std::cout << std::endl;
int opcode = *ptr % 100;
int digits[6] = {0,0,0,0,0};
for (int i = 0; i < 6; ++i)
{
int current = (*ptr/(int)pow(10,i)) % 10;
digits[5-i] = current;
};
// int op = digits[5];
// std::cout << "op: " << opcode << std::endl;
int mem1 = -1;
int mem2 = -1;
int mem3 = -1;
if (opcode != 99)
{
mem1 = digits[3] == 0 ? memory[*(ptr+1)] : *(ptr+1);
if (opcode < 3 || opcode == 7 || opcode == 8 || opcode == 5 || opcode == 6)
{
mem2 = digits[2] == 0 ? memory[*(ptr+2)] : *(ptr+2);
mem3 = *(ptr+3);
}
}
// int mem2 = *(ptr+2);
// int mem3 = *(ptr+3);
// if digits[4] == 0
// if(mem1 >= mem_size || mem2 >= mem_size || mem3 >= mem_size)
// {
// std::cout << "invalid pointer" << std::endl;
// should_exit = 1;
// }
switch (opcode)
{
case 1:
memory[mem3] = mem1 + mem2;
ptr += 4;
break;
case 2:
memory[mem3] = mem1 * mem2;
ptr += 4;
break;
case 3:
memory[*(ptr+1)] = INPUT;
ptr += 2;
break;
case 4:
std::cout << "OUTPUT: " << mem1 << std::endl;
ptr += 2;
break;
case 5: // jmp if true
// jump to mem2 if mem1 != 0 else go to next
ptr = mem1 != 0 ? memory + mem2 : ptr + 3;
break;
case 6: // jmp if false
// jump to mem2 if mem1 != 0 else go to next
ptr = mem1 == 0 ? memory + mem2 : ptr + 3;
break;
case 7: // <
memory[mem3] = mem1 < mem2 ? 1 : 0;
ptr += 4;
break;
case 8: // ==
memory[mem3] = mem1 == mem2 ? 1 : 0;
ptr += 4;
break;
case 99:
// std::cout << "exit " << std::endl;
should_exit = 1;
break;
default:
std::cout << "invalid op code: " << *ptr << std::endl;
should_exit = 1;
break;
}
}
// std::cout << "-----------------" << std::endl;
// for(int *ptr = memory; ptr < end; ++ptr)
// std::cout << *ptr << ", ";
// std::cout << std::endl;
}
| [
"ph.mongeau@gmail.com"
] | ph.mongeau@gmail.com |
04e906b69160d72ccf4508c6b0662f4af16656a9 | 1dbdf74191d0627d22668403263580ba668f1ef1 | /FrameData.cpp | 919ccce4a165adc6b42dfd20ed4e1953caeabadf | [] | no_license | josey822000/stereo | 65d24688eab3dad60df51446dc4a3a3af41c407e | 205d98ab815fda5bfe20313b28c4042c67c98cbf | refs/heads/master | 2021-03-12T19:25:20.180460 | 2013-02-22T12:29:32 | 2013-02-22T12:29:32 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 493 | cpp | #include "FrameData.h"
#include <iostream>
CvMat* FrameData::getD(){
if (! b_dis){
std::cout << "No disparity in FrameData!" << endl;
return 0;
}
else
return _D;
}
CvMat* FrameData::getMask(){
if( ! b_mask){
std::cout << "No mask in FrameData!" << endl;
return 0;
}
else
return _mask;
}
FrameData::~FrameData(){
cvReleaseImage(&_img);
cvReleaseMat(&_K);
cvReleaseMat(&_R);
cvReleaseMat(&_T);
cvReleaseMat(&_D);
cvReleaseMat(&_mask);
} | [
"josey822000@hotmail.com"
] | josey822000@hotmail.com |
1851dd4ee50dbdc85e20ce7d5a9c64b6681b79bf | d6292bb708a38c46dd0bef488b0be542fd6e86ce | /CodeMonk/Basics of Programming/Basics of Input Output/Seven Segment Display.cpp | 6035088378edc602fcf7c9109089364e31b9747e | [] | no_license | prantostic/HackerEarth | 3fe1f35f34f9060ca0bcb02834b89a49885847cb | 913f77556257b03ad345620779231f900bec0c2b | refs/heads/master | 2020-11-24T22:44:16.461286 | 2020-03-04T16:20:12 | 2020-03-04T16:20:12 | 228,370,108 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 452 | cpp | #include <iostream>
using namespace std;
int main(int argc, char const *argv[]) {
ios_base::sync_with_stdio(0);
cin.tie(nullptr);
int t, n;
string num;
int array[10] = {6, 2, 5, 5, 4, 5, 6, 3, 7, 6};
cin >> t;
while (t--) {
cin >> num;
n = 0;
for (auto &i : num) {
n += array[i - '0'];
}
string ans(n / 2, '1');
if (n % 2 != 0) {
ans.erase(0, 1);
ans.insert(ans.cbegin(), '7');
}
cout << ans << "\n";
}
return 0;
}
| [
"pranavchaudhary2310@gmail.com"
] | pranavchaudhary2310@gmail.com |
6deacab0a19e991206427bea8b0d8e08cca6081b | 39c4b60a9a32a776385b4ab028a1650f2fda9039 | /feather-neomatrix-bluetooth-snowflake/feather-neomatrix-bluetooth-snowflake.ino | 18e81f174cacd206eaad7073cd59eea258e3c054 | [
"MIT"
] | permissive | adafruit/Bluefruit-NeoMatrix-Snowflake | 8849ef50090d59fe4539da6ca935a248347420de | 77c474317bddfacaa810f7d4b8f62f87edaf5436 | refs/heads/master | 2021-01-10T14:47:18.148568 | 2019-05-02T21:27:05 | 2019-05-02T21:27:05 | 48,254,092 | 6 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 19,676 | ino | /*********************************************************************
This is an example for our nRF51822 based Bluefruit LE modules
Pick one up today in the adafruit shop!
Adafruit invests time and resources providing this open source code,
please support Adafruit and open-source hardware by purchasing
products from Adafruit!
MIT license, check LICENSE for more information
All text above, and the splash screen below must be included in
any redistribution
*********************************************************************/
#include <string.h>
#include <Arduino.h>
#include <SPI.h>
#if not defined (_VARIANT_ARDUINO_DUE_X_) && not defined (_VARIANT_ARDUINO_ZERO_)
#include <SoftwareSerial.h>
#endif
#include "Adafruit_BLE.h"
#include "Adafruit_BluefruitLE_SPI.h"
#include "Adafruit_BluefruitLE_UART.h"
#include "BluefruitConfig.h"
#include <Adafruit_NeoPixel.h>
#include <Adafruit_GFX.h>
#include <Adafruit_NeoMatrix.h>
/*=========================================================================
APPLICATION SETTINGS
FACTORYRESET_ENABLE Perform a factory reset when running this sketch
Enabling this will put your Bluefruit LE module
in a 'known good' state and clear any config
data set in previous sketches or projects, so
running this at least once is a good idea.
When deploying your project, however, you will
want to disable factory reset by setting this
value to 0. If you are making changes to your
Bluefruit LE device via AT commands, and those
changes aren't persisting across resets, this
is the reason why. Factory reset will erase
the non-volatile memory where config data is
stored, setting it back to factory default
values.
Some sketches that require you to bond to a
central device (HID mouse, keyboard, etc.)
won't work at all with this feature enabled
since the factory reset will clear all of the
bonding data stored on the chip, meaning the
central device won't be able to reconnect.
MATRIX DECLARATION Parameter 1 = width of NeoPixel matrix
Parameter 2 = height of matrix
Parameter 3 = pin number (most are valid)
Parameter 4 = matrix layout flags, add together as needed:
NEO_MATRIX_TOP,
NEO_MATRIX_BOTTOM,
NEO_MATRIX_LEFT,
NEO_MATRIX_RIGHT Position of the FIRST LED in the matrix; pick two, e.g.
NEO_MATRIX_TOP + NEO_MATRIX_LEFT for the top-left corner.
NEO_MATRIX_ROWS, NEO_MATRIX_COLUMNS: LEDs are arranged in horizontal
rows or in vertical columns, respectively; pick one or the other.
NEO_MATRIX_PROGRESSIVE,
NEO_MATRIX_ZIGZAG all rows/columns proceed in the same order,
or alternate lines reverse direction; pick one.
See example below for these values in action.
Parameter 5 = pixel type flags, add together as needed:
NEO_KHZ800 800 KHz bitstream (most NeoPixel products w/WS2812 LEDs)
NEO_KHZ400 400 KHz (classic 'v1' (not v2) FLORA pixels, WS2811 drivers)
NEO_GRB Pixels are wired for GRB bitstream (most NeoPixel products)
NEO_RGB Pixels are wired for RGB bitstream (v1 FLORA pixels, not v2)
-----------------------------------------------------------------------*/
#define FACTORYRESET_ENABLE 1
#define PIN 6 // Which pin on the Arduino is connected to the NeoPixels?
// Example for NeoPixel 8x8 Matrix. In this application we'd like to use it
// with the back text positioned along the bottom edge.
// When held that way, the first pixel is at the top left, and
// lines are arranged in columns, zigzag order. The 8x8 matrix uses
// 800 KHz (v2) pixels that expect GRB color data.
Adafruit_NeoMatrix matrix = Adafruit_NeoMatrix(8, 8, PIN,
NEO_MATRIX_TOP + NEO_MATRIX_LEFT +
NEO_MATRIX_COLUMNS + NEO_MATRIX_ZIGZAG,
NEO_GRB + NEO_KHZ800);
/*=========================================================================*/
// Create the bluefruit object, either software serial...uncomment these lines
/*
SoftwareSerial bluefruitSS = SoftwareSerial(BLUEFRUIT_SWUART_TXD_PIN, BLUEFRUIT_SWUART_RXD_PIN);
Adafruit_BluefruitLE_UART ble(bluefruitSS, BLUEFRUIT_UART_MODE_PIN,
BLUEFRUIT_UART_CTS_PIN, BLUEFRUIT_UART_RTS_PIN);
*/
/* ...or hardware serial, which does not need the RTS/CTS pins. Uncomment this line */
// Adafruit_BluefruitLE_UART ble(BLUEFRUIT_HWSERIAL_NAME, BLUEFRUIT_UART_MODE_PIN);
/* ...hardware SPI, using SCK/MOSI/MISO hardware SPI pins and then user selected CS/IRQ/RST */
Adafruit_BluefruitLE_SPI ble(BLUEFRUIT_SPI_CS, BLUEFRUIT_SPI_IRQ, BLUEFRUIT_SPI_RST);
/* ...software SPI, using SCK/MOSI/MISO user-defined SPI pins and then user selected CS/IRQ/RST */
//Adafruit_BluefruitLE_SPI ble(BLUEFRUIT_SPI_SCK, BLUEFRUIT_SPI_MISO,
// BLUEFRUIT_SPI_MOSI, BLUEFRUIT_SPI_CS,
// BLUEFRUIT_SPI_IRQ, BLUEFRUIT_SPI_RST);
// A small helper
void error(const __FlashStringHelper*err) {
Serial.println(err);
while (1);
}
// function prototypes over in packetparser.cpp
uint8_t readPacket(Adafruit_BLE *ble, uint16_t timeout);
float parsefloat(uint8_t *buffer);
void printHex(const uint8_t * data, const uint32_t numBytes);
// the packet buffer
extern uint8_t packetbuffer[];
/**************************************************************************/
/*!
@brief Sets up the HW an the BLE module (this function is called
automatically on startup)
*/
/**************************************************************************/
//additional variables
//Color
uint8_t red = 100;
uint8_t green = 100;
uint8_t blue = 100;
uint8_t animationState = 1;
void setup(void)
{
//while (!Serial); // required for Flora & Micro
delay(500);
matrix.begin();
matrix.setBrightness(40);
matrix.fillScreen(0);
showAllSnowflakes(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
Serial.begin(115200);
Serial.println(F("Adafruit Bluefruit NeoMatrix Snowflake"));
Serial.println(F("------------------------------------------------"));
/* Initialise the module */
Serial.print(F("Initialising the Bluefruit LE module: "));
if ( !ble.begin(VERBOSE_MODE) )
{
error(F("Couldn't find Bluefruit, make sure it's in CoMmanD mode & check wiring?"));
}
Serial.println( F("OK!") );
if ( FACTORYRESET_ENABLE )
{
/* Perform a factory reset to make sure everything is in a known state */
Serial.println(F("Performing a factory reset: "));
if ( ! ble.factoryReset() ){
error(F("Couldn't factory reset"));
}
}
/* Disable command echo from Bluefruit */
ble.echo(false);
Serial.println("Requesting Bluefruit info:");
/* Print Bluefruit information */
ble.info();
Serial.println(F("Please use Adafruit Bluefruit LE app to connect in Controller mode"));
Serial.println(F("Then activate/use the color picker and controller!"));
Serial.println();
ble.verbose(false); // debug info is a little annoying after this point!
/* Wait for connection */
while (! ble.isConnected()) {
delay(500);
}
Serial.println(F("***********************"));
// Set Bluefruit to DATA mode
Serial.println( F("Switching to DATA mode!") );
ble.setMode(BLUEFRUIT_MODE_DATA);
Serial.println(F("***********************"));
}
/**************************************************************************/
/*!
@brief Constantly poll for new command or response data
*/
/**************************************************************************/
void loop(void)
{
/* Wait for new data to arrive */
uint8_t len = readPacket(&ble, BLE_READPACKET_TIMEOUT);
//if (len == 0) return;
/* Got a packet! */
// printHex(packetbuffer, len);
// Color
if (packetbuffer[1] == 'C') {
red = packetbuffer[2];
green = packetbuffer[3];
blue = packetbuffer[4];
Serial.print ("RGB #");
if (red < 0x10) Serial.print("0");
Serial.print(red, HEX);
if (green < 0x10) Serial.print("0");
Serial.print(green, HEX);
if (blue < 0x10) Serial.print("0");
Serial.println(blue, HEX);
}
// Buttons
if (packetbuffer[1] == 'B') {
uint8_t buttnum = packetbuffer[2] - '0';
boolean pressed = packetbuffer[3] - '0';
Serial.print ("Button "); Serial.print(buttnum);
animationState = buttnum;
if (pressed) {
Serial.println(" pressed");
} else {
Serial.println(" released");
}
}
if (animationState == 1){ // animate through all the snowflakes
matrix.fillScreen(0);
showAllSnowflakes(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
}
if (animationState == 2){
matrix.fillScreen(0);
SnowFlake2(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
}
if (animationState == 3){
matrix.fillScreen(0);
SnowFlake3(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
}
if (animationState == 4){
matrix.fillScreen(0);
SnowFlake4(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
}
if (animationState == 5){
matrix.fillScreen(0);
SnowFlake5(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
}
if (animationState == 6){
matrix.fillScreen(0);
SnowFlake6(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
}
if (animationState == 7){
matrix.fillScreen(0);
SnowFlake7(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
}
if (animationState == 8){
matrix.fillScreen(0);
SnowFlake8(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
}
}
void SnowFlake1(uint32_t c){
matrix.drawLine(0, 2, 2, 0, c); // x0, y0, x1, y1, color
matrix.drawLine(4, 0, 6, 2, c); // x0, y0, x1, y1, color
matrix.drawLine(0, 4, 2, 6, c); // x0, y0, x1, y1, color
matrix.drawLine(4, 6, 6, 4, c); // x0, y0, x1, y1, color
matrix.drawFastVLine(3, 0, 7, c); // x0, y0, length, color
matrix.drawFastHLine(0, 3, 7, c); // x0, y0, length, color
matrix.drawPixel(3, 3, 0); // x, y, color
}
void SnowFlake2(uint32_t c){
matrix.drawFastVLine(3, 0, 7, c); // x0, y0, length, color
matrix.drawFastHLine(0, 3, 7, c); // x0, y0, length, color
matrix.drawLine(1, 1, 5, 5, c); // x0, y0, x1, y1, color
matrix.drawLine(1, 5, 5, 1, c); // x0, y0, x1, y1, color
matrix.drawPixel(3, 3, 0); // x, y, color
}
void SnowFlake3(uint32_t c){
matrix.drawLine(0, 2, 2, 0, c); // x0, y0, x1, y1, color
matrix.drawLine(0, 4, 4, 0, c); // x0, y0, x1, y1, color
matrix.drawLine(1, 5, 5, 1, c); // x0, y0, x1, y1, color
matrix.drawPixel(3, 3, 0); // x, y, color
matrix.drawRect(2, 2, 3, 3, c); // x0, y0, width, height
matrix.drawLine(2, 6, 6, 2, c); // x0, y0, x1, y1, color
matrix.drawLine(4, 6, 6, 4, c); // x0, y0, x1, y1, color
}
void SnowFlake4(uint32_t c){
matrix.drawRect(2, 2, 3, 3, c); // x0, y0, width, height
matrix.drawLine(0, 3, 3, 0, c); // x0, y0, x1, y1, color
matrix.drawLine(3, 6, 6, 3, c); // x0, y0, x1, y1, color
matrix.drawLine(4, 1, 5, 2, c); // x0, y0, x1, y1, color
matrix.drawLine(1, 4, 2, 5, c); // x0, y0, x1, y1, color
matrix.drawPixel(0, 0, c); // x, y, color
matrix.drawPixel(0, 6, c); // x, y, color
matrix.drawPixel(6, 0, c); // x, y, color
matrix.drawPixel(6, 6, c); // x, y, color
}
void SnowFlake5(uint32_t c){
matrix.fillRect(1, 1, 5, 5, c); // x0, y0, width, height
matrix.drawLine(0, 3, 3, 0, c); // x0, y0, x1, y1, color
matrix.drawLine(3, 6, 6, 3, c); // x0, y0, x1, y1, color
matrix.drawLine(1, 3, 3, 1, 0); // x0, y0, x1, y1, color
matrix.drawLine(3, 5, 5, 3, 0); // x0, y0, x1, y1, color
matrix.drawPixel(2, 4, 0); // x, y, color
matrix.drawPixel(4, 2, 0); // x, y, color
}
void SnowFlake6(uint32_t c){
matrix.fillRect(1, 1, 5, 5, c); // x0, y0, width, height
matrix.drawLine(1, 1, 5, 5, 0); // x0, y0, x1, y1, color
matrix.drawLine(1, 5, 5, 1, 0); // x0, y0, x1, y1, color
matrix.drawPixel(0, 3, c); // x, y, color
matrix.drawPixel(3, 0, c); // x, y, color
matrix.drawPixel(3, 6, c); // x, y, color
matrix.drawPixel(6, 3, c); // x, y, color
}
void SnowFlake7(uint32_t c){
matrix.drawRect(2, 2, 3, 3, c); // x0, y0, width, height
matrix.drawFastVLine(3, 0, 7, c); // x0, y0, length, color
matrix.drawFastHLine(0, 3, 7, c); // x0, y0, length, color
matrix.drawFastVLine(3, 0, 7, c); // x0, y0, length, color
matrix.drawFastHLine(0, 3, 7, c); // x0, y0, length, color
matrix.drawPixel(3, 3, 0); // x, y, color
matrix.drawFastHLine(2, 0, 3, c); // x0, y0, length, color
matrix.drawFastHLine(2, 6, 3, c); // x0, y0, length, color
matrix.drawFastVLine(0, 2, 3, c); // x0, y0, length, color
matrix.drawFastVLine(6, 2, 3, c); // x0, y0, length, color
}
void SnowFlake8(uint32_t c){
//four corners
matrix.drawPixel(0, 0, c); // x, y, color
matrix.drawPixel(0, 6, c); // x, y, color
matrix.drawPixel(6, 0, c); // x, y, color
matrix.drawPixel(6, 6, c); // x, y, color
//upper left corner
matrix.drawLine(0, 2, 2, 0, c); // x0, y0, x1, y1, color
matrix.drawLine(0, 3, 3, 0, c); // x0, y0, x1, y1, color
//center dot
matrix.drawPixel(3, 3, c); // x, y, color
//upper right corner
matrix.drawLine(4, 0, 6, 2, c); // x0, y0, x1, y1, color
matrix.drawLine(3, 0, 6, 3, c); // x0, y0, x1, y1, color
//lower left corner
matrix.drawLine(0, 3, 3, 6, c); // x0, y0, x1, y1, color
matrix.drawLine(0, 4, 2, 6, c); // x0, y0, x1, y1, color
//lower right corner
matrix.drawLine(3, 6, 6, 3, c); // x0, y0, x1, y1, color
matrix.drawLine(4, 6, 6, 4, c); // x0, y0, x1, y1, color
}
void SnowFlake9(uint32_t c){
//four corners
matrix.drawPixel(0, 0, c); // x, y, color
matrix.drawPixel(0, 6, c); // x, y, color
matrix.drawPixel(6, 0, c); // x, y, color
matrix.drawPixel(6, 6, c); // x, y, color
//center dot
matrix.drawPixel(3, 3, c); // x, y, color
//four boxes near center
matrix.drawRect(1, 1, 2, 2, c); // x0, y0, width, height
matrix.drawRect(4, 1, 2, 2, c); // x0, y0, width, height
matrix.drawRect(1, 4, 2, 2, c); // x0, y0, width, height
matrix.drawRect(4, 4, 2, 2, c); // x0, y0, width, height
//clear out corner pixel of boxes
matrix.drawPixel(1, 1, 0); // x, y, color
matrix.drawPixel(5, 1, 0); // x, y, color
matrix.drawPixel(1, 5, 0); // x, y, color
matrix.drawPixel(5, 5, 0); // x, y, color
}
void SnowFlake10(uint32_t c){
//lines across the corners
matrix.drawLine(0, 1, 1, 0, c); // x0, y0, x1, y1, color
matrix.drawLine(5, 0, 6, 1, c); // x0, y0, x1, y1, color
matrix.drawLine(0, 5, 1, 6, c); // x0, y0, x1, y1, color
matrix.drawLine(5, 6, 6, 5, c); // x0, y0, x1, y1, color
//center dot
matrix.drawPixel(3, 3, c); // x, y, color
//four boxes near center
matrix.drawRect(1, 1, 2, 2, c); // x0, y0, width, height
matrix.drawRect(4, 1, 2, 2, c); // x0, y0, width, height
matrix.drawRect(1, 4, 2, 2, c); // x0, y0, width, height
matrix.drawRect(4, 4, 2, 2, c); // x0, y0, width, height
//clear out corner pixel of boxes
matrix.drawPixel(1, 1, 0); // x, y, color
matrix.drawPixel(5, 1, 0); // x, y, color
matrix.drawPixel(1, 5, 0); // x, y, color
matrix.drawPixel(5, 5, 0); // x, y, color
}
void SnowFlake11(uint32_t c){
//corner lines
matrix.drawLine(0, 2, 2, 0, c); // x0, y0, x1, y1, color
matrix.drawLine(4, 0, 6, 2, c); // x0, y0, x1, y1, color
matrix.drawLine(0, 4, 2, 6, c); // x0, y0, x1, y1, color
matrix.drawLine(4, 6, 6, 4, c); // x0, y0, x1, y1, color
//center X
matrix.drawLine(2, 2, 4, 4, c); // x0, y0, x1, y1, color
matrix.drawLine(2, 4, 4, 2, c); // x0, y0, x1, y1, color
}
//8x8
void SnowFlake12(uint32_t c){
matrix.drawLine(1, 1, 6, 6, c); // x0, y0, x1, y1, color
matrix.drawLine(1, 6, 6, 1, c); // x0, y0, x1, y1, color
matrix.fillRect(3, 0, 2, 2, c); // x0, y0, width, height
matrix.fillRect(0, 3, 2, 2, c); // x0, y0, width, height
matrix.fillRect(6, 3, 2, 2, c); // x0, y0, width, height
matrix.fillRect(3, 6, 2, 2, c); // x0, y0, width, height
matrix.show();
}
void showAllSnowflakes(uint32_t c){
SnowFlake1(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
delay(500);
matrix.fillScreen(0);
SnowFlake5(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
delay(500);
matrix.fillScreen(0);
SnowFlake2(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
delay(500);
matrix.fillScreen(0);
SnowFlake8(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
delay(500);
matrix.fillScreen(0);
SnowFlake3(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
delay(500);
matrix.fillScreen(0);
SnowFlake9(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
delay(500);
matrix.fillScreen(0);
SnowFlake4(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
delay(500);
matrix.fillScreen(0);
SnowFlake10(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
delay(500);
matrix.fillScreen(0);
SnowFlake6(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
delay(500);
matrix.fillScreen(0);
SnowFlake11(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
delay(500);
matrix.fillScreen(0);
SnowFlake7(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
delay(500);
matrix.fillScreen(0);
SnowFlake11(matrix.Color(red, green, blue));
matrix.show(); // This sends the updated pixel colors to the hardware.
delay(500);
}
| [
"beckystern@iMac.local"
] | beckystern@iMac.local |
9e3698f05d7a2065fdda3e3303801ee51f49196a | 0a9a614314f9bb804b33b011fdcb297929b2c896 | /CTest11.1(catchRect)/CTest11.1(catchRect)/stdafx.cpp | 0961424068ec745d8ea84f9e803137867d7e45a3 | [] | no_license | WSJ-github/MFC | f217d6bb0881c6ec8d0091eb9406823be1da513d | 64d264f183f6f1fda5d4d3f42d4385b8780b40fa | refs/heads/master | 2021-03-26T16:18:26.672169 | 2020-06-08T16:16:26 | 2020-06-08T16:16:26 | 247,721,744 | 0 | 0 | null | null | null | null | GB18030 | C++ | false | false | 175 | cpp |
// stdafx.cpp : 只包括标准包含文件的源文件
// CTest11.1(catchRect).pch 将作为预编译头
// stdafx.obj 将包含预编译类型信息
#include "stdafx.h"
| [
"963013061@qq.com"
] | 963013061@qq.com |
39ab682e84ca2db2921712b26dc5b28d28c9ba5a | b07ce3cc46e1a2a638d867a602bc37e15e3f786d | /src/UpCloud-Core/DatabaseLib/db/conf/databaseconf.cpp | 68f716fecaa3c58e87cb65f50d1a2e120b76d196 | [] | no_license | Lynzabo/UpCloudEcosphere | 9c4b12585aedffdf9f9b982f5345357efd406b12 | c7ce266f627dd6570e6b9d7606cd7e2b90bf8f9a | refs/heads/master | 2021-01-06T20:39:02.722381 | 2017-08-07T04:07:46 | 2017-08-07T04:08:01 | 99,533,490 | 2 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 2,517 | cpp | #include "databaseconf.h"
SINGLETON_INITIALIZE(DatabaseConf)
DatabaseConf::DatabaseConf() {
}
DatabaseConf::~DatabaseConf() {
delete settings;
settings = NULL;
}
void DatabaseConf::setConfPath(const QString &confPath)
{
this->confPath = confPath;
}
void DatabaseConf::loadConf()
{
// 配置文件路径
settings = new QSettings(confPath, QSettings::IniFormat);
}
QString DatabaseConf::dbName() const
{
return settings->value("upCloud.database.dbName",QString()).toString();
}
QString DatabaseConf::dbDriver() const
{
const QString dbLowerName = settings->value("upCloud.database.dbName",QString()).toString().toLower();
if(dbLowerName=="oracle")
return trs("QOCI");
else if(dbLowerName=="db2")
return trs("QDB2");
else if(dbLowerName=="mysql")
return trs("QMYSQL");
else if(dbLowerName=="sqlserver")
return trs("QODBC");
else if(dbLowerName=="sqlite2")
return trs("QSQLITE2");
else
return trs("QSQLITE");
}
QString DatabaseConf::ip() const
{
return settings->value("upCloud.database.ip",QString("127.0.0.1")).toString();
}
int DatabaseConf::port() const
{
return settings->value("upCloud.database.port",0).toInt();
}
QString DatabaseConf::instanceName() const
{
return settings->value("upCloud.database.instanceName",QString()).toString();
}
QString DatabaseConf::username() const
{
return settings->value("upCloud.database.username",QString()).toString();
}
QString DatabaseConf::password() const
{
return settings->value("upCloud.database.password",QString()).toString();
}
int DatabaseConf::houseKeepingSleepTime() const
{
return settings->value("upCloud.database.houseKeepingSleepTime",1000).toInt();
}
int DatabaseConf::waitIntervalTime() const
{
return settings->value("upCloud.database.waitIntervalTime",200).toInt();
}
int DatabaseConf::maximumConnectionCount() const
{
return settings->value("upCloud.database.maximumConnectionCount",100).toInt();
}
int DatabaseConf::minimumConnectionCount() const
{
return settings->value("upCloud.database.minimumConnectionCount",0).toInt();
}
bool DatabaseConf::isDebug() const
{
return settings->value("upCloud.database.debug",true).toBool();
}
bool DatabaseConf::testOnBorrow() const
{
return settings->value("upCloud.database.testOnBorrow",true).toBool();
}
QString DatabaseConf::testOnBorrowSql() const
{
return settings->value("upCloud.database.testOnBorrowSql",QString("select 1")).toString();
}
| [
"linzhanbo@le.com"
] | linzhanbo@le.com |
7b85735d045dd35585e6685d2305b720d29d5332 | 425386c14f9b576801e861d2d6a11bfb6b89b704 | /BinaryTreeMaximumPathSum/MaxPathSum/main.cpp | 63dcf728576f6a0d649959ba0444497d61c3411d | [] | no_license | tianyangche/leetcode-1 | e7323e2adcf4a6c74793b844a978a3ff3fd903b7 | c2d276c0777328381039633ebea5189fe5444169 | refs/heads/master | 2021-01-01T19:29:26.312637 | 2013-11-13T21:39:41 | 2013-11-13T21:39:41 | 16,220,915 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 300 | cpp | #include <iostream>
#include "MaxPathSum.h"
using namespace std;
int main() {
TreeNode node1(0);
TreeNode node2(1);
TreeNode node3(1);
node1.left = &node2;
node1.right = &node3;
MaxPathSum maxPathSum;
int result = maxPathSum.maxPathSum(&node1);
cout << result << endl;
system("pause");
} | [
"shuk.xie@gmail.com"
] | shuk.xie@gmail.com |
166206013ef5efda66eb50be4e78ef29747af187 | d7085a2924fb839285146f88518c69c567e77968 | /KS/SRC/convex_box.cpp | 86abbb77c655a12525beefd6fc12e79214e116dd | [] | no_license | historicalsource/kelly-slaters-pro-surfer | 540f8f39c07e881e9ecebc764954c3579903ad85 | 7c3ade041cc03409a3114ce3ba4a70053c6e4e3b | refs/heads/main | 2023-07-04T09:34:09.267099 | 2021-07-29T19:35:13 | 2021-07-29T19:35:13 | 390,831,183 | 40 | 2 | null | null | null | null | UTF-8 | C++ | false | false | 878 | cpp | #include "global.h"
#include "convex_box.h"
convex_box::convex_box( const convex_box& _box )
{
for( int i = 0; i < 6; i++ ) {
planes[i] = _box.planes[i];
}
bbox = _box.bbox;
}
void serial_in( chunk_file& fs, convex_box* box )
{
chunk_flavor cf;
for( serial_in( fs, &cf ); cf != CHUNK_END; serial_in( fs, &cf ) ) {
if( chunk_flavor( "planes" ) == cf ) {
for( int i = 0; i < 6; i++ ) {
vector4d plane;
serial_in( fs, &plane );
box->planes[i] = plane;
}
} else if( chunk_flavor( "bbox" ) == cf ) {
bounding_box bbox;
serial_in( fs, &bbox.vmin );
serial_in( fs, &bbox.vmax );
box->bbox = bbox;
} else {
stringx msg = stringx( "unknown chunk type '" ) + cf.to_stringx() + "' in '" + fs.get_name( );
error( msg.c_str( ) );
}
}
} | [
"root@teamarchive2.fnf.archive.org"
] | root@teamarchive2.fnf.archive.org |
8a1ff467d8f3a3021332df152aca85b71145df80 | e331e4f0c321b98acde31faf3548194ae6d7d14b | /src/wallet/test/wallet_test_fixture.h | 7d066a180f8a6529b324ac41e81063186b8fcd21 | [
"MIT"
] | permissive | MB8Coin/mb8coin-core | 487e3e16e43c008a6913d92e6edcf428c67a1f50 | 1fa5bd60019f6cff8038ace509ec4ca17c8233c7 | refs/heads/master | 2021-10-27T07:12:31.935401 | 2021-10-19T19:02:31 | 2021-10-19T19:02:31 | 131,882,320 | 5 | 3 | MIT | 2019-05-24T14:29:38 | 2018-05-02T17:10:21 | C++ | UTF-8 | C++ | false | false | 513 | h | // Copyright (c) 2016 The Bitcoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#ifndef MB8COIN_WALLET_TEST_FIXTURE_H
#define MB8COIN_WALLET_TEST_FIXTURE_H
#include "test/test_mb8coin.h"
/** Testing setup and teardown for wallet.
*/
struct WalletTestingSetup: public TestingSetup {
WalletTestingSetup(const std::string& chainName = CBaseChainParams::MAIN);
~WalletTestingSetup();
};
#endif
| [
"vidaru@protonmail.com"
] | vidaru@protonmail.com |
35ffe3e1f9e7ca2d4a76b9c028a3a5d8b1c9e5bf | 6b8873065d10d0082760236744bad4a490393086 | /Rocface/CGAL/include/CGAL/predicates/kernel_ftC3.h | c3b00da611868dc6bf3e2f0fdf9e7111a2a9542b | [
"NCSA",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | XiSheng1998/Rocstar | ec32443f67187069fb37ce5d187bc2c43da016b7 | 7a0f3147ac81503e4347be39288c9bedbe358a39 | refs/heads/master | 2022-12-27T12:50:32.652912 | 2018-11-26T08:30:28 | 2018-11-26T08:30:28 | 216,749,801 | 1 | 0 | null | 2019-10-22T07:26:51 | 2019-10-22T07:26:51 | null | UTF-8 | C++ | false | false | 12,693 | h | // ======================================================================
//
// Copyright (c) 2000 The CGAL Consortium
// This software and related documentation is part of the Computational
// Geometry Algorithms Library (CGAL).
// This software and documentation is provided "as-is" and without warranty
// of any kind. In no event shall the CGAL Consortium be liable for any
// damage of any kind.
//
// Every use of CGAL requires a license.
//
// Academic research and teaching license
// - For academic research and teaching purposes, permission to use and copy
// the software and its documentation is hereby granted free of charge,
// provided that it is not a component of a commercial product, and this
// notice appears in all copies of the software and related documentation.
//
// Commercial licenses
// - A commercial license is available through Algorithmic Solutions, who also
// markets LEDA (http://www.algorithmic-solutions.de).
// - Commercial users may apply for an evaluation license by writing to
// Algorithmic Solutions (contact@algorithmic-solutions.com).
//
// The CGAL Consortium consists of Utrecht University (The Netherlands),
// ETH Zurich (Switzerland), Free University of Berlin (Germany),
// INRIA Sophia-Antipolis (France), Martin-Luther-University Halle-Wittenberg
// (Germany), Max-Planck-Institute Saarbrucken (Germany), RISC Linz (Austria),
// and Tel-Aviv University (Israel).
//
// ----------------------------------------------------------------------
//
// release : CGAL-2.2
// release_date : 2000, September 30
//
// file : include/CGAL/predicates/kernel_ftC3.h
// package : C3 (5.2)
// revision : $Revision: 1.1.1.1 $
// revision_date : $Date: 2001/07/05 22:17:49 $
// author(s) : Herve Bronnimann, Sylvain Pion
// coordinator : INRIA Sophia-Antipolis
//
// email : contact@cgal.org
// www : http://www.cgal.org
//
// ======================================================================
#ifndef CGAL_PREDICATES_KERNEL_FTC3_H
#define CGAL_PREDICATES_KERNEL_FTC3_H
#include <CGAL/predicates/sign_of_determinant.h>
#include <CGAL/predicates/kernel_ftC2.h>
#include <CGAL/constructions/kernel_ftC3.h>
CGAL_BEGIN_NAMESPACE
template < class FT >
/*CGAL_NO_FILTER*/
CGAL_KERNEL_MEDIUM_INLINE
Comparison_result
compare_lexicographically_xyzC3(const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz)
{
Comparison_result c = CGAL_NTS compare(px, qx);
if (c != EQUAL) return c;
c = CGAL_NTS compare(py, qy);
if (c != EQUAL) return c;
return CGAL_NTS compare(pz, qz);
}
template < class FT >
CGAL_KERNEL_MEDIUM_INLINE
bool
strict_dominanceC3(const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz)
{
return CGAL_NTS compare(px, qx) == LARGER &&
CGAL_NTS compare(py, qy) == LARGER &&
CGAL_NTS compare(pz, qz) == LARGER;
}
template < class FT >
CGAL_KERNEL_MEDIUM_INLINE
bool
dominanceC3(const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz)
{
return CGAL_NTS compare(px, qx) != SMALLER &&
CGAL_NTS compare(py, qy) != SMALLER &&
CGAL_NTS compare(pz, qz) != SMALLER;
}
template < class FT >
CGAL_KERNEL_MEDIUM_INLINE
bool
collinearC3(const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz,
const FT &rx, const FT &ry, const FT &rz)
{
FT dpx = px-rx;
FT dqx = qx-rx;
FT dpy = py-ry;
FT dqy = qy-ry;
if (sign_of_determinant2x2(dpx, dqx, dpy, dqy) != ZERO)
return false;
FT dpz = pz-rz;
FT dqz = qz-rz;
return sign_of_determinant2x2(dpx, dqx, dpz, dqz) == ZERO
&& sign_of_determinant2x2(dpy, dqy, dpz, dqz) == ZERO;
}
template < class FT >
CGAL_KERNEL_MEDIUM_INLINE
Orientation
orientationC3(const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz,
const FT &rx, const FT &ry, const FT &rz,
const FT &sx, const FT &sy, const FT &sz)
{
return Orientation(sign_of_determinant3x3(qx-px,rx-px,sx-px,
qy-py,ry-py,sy-py,
qz-pz,rz-pz,sz-pz));
}
template < class FT >
/*CGAL_NO_FILTER*/
CGAL_KERNEL_MEDIUM_INLINE
Orientation
coplanar_orientationC3(const FT &qx, const FT &qy, const FT &qz,
const FT &rx, const FT &ry, const FT &rz,
const FT &sx, const FT &sy, const FT &sz,
const FT &px, const FT &py, const FT &pz)
{
Orientation oxy_qrs = orientationC2(qx,qy,rx,ry,sx,sy);
if (oxy_qrs != COLLINEAR)
return Orientation( oxy_qrs * orientationC2(qx,qy,rx,ry,px,py));
Orientation oyz_qrs = orientationC2(qy,qz,ry,rz,sy,sz);
if (oyz_qrs != COLLINEAR)
return Orientation( oyz_qrs * orientationC2(qy,qz,ry,rz,py,pz));
Orientation oxz_qrs = orientationC2(qx,qz,rx,rz,sx,sz);
assert(oxz_qrs != COLLINEAR);
return Orientation( oxz_qrs * orientationC2(qx,qz,rx,rz,px,pz));
}
template < class FT >
/*CGAL_NO_FILTER*/
CGAL_KERNEL_MEDIUM_INLINE
bool
collinear_are_ordered_along_lineC3(
const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz,
const FT &rx, const FT &ry, const FT &rz)
{
if (px < qx) return !(rx < qx);
if (qx < px) return !(qx < rx);
if (py < qy) return !(ry < qy);
if (qy < py) return !(qy < ry);
if (pz < qz) return !(rz < qz);
if (qz < pz) return !(qz < rz);
return true; // p==q
}
template < class FT >
/*CGAL_NO_FILTER*/
CGAL_KERNEL_MEDIUM_INLINE
bool
collinear_are_strictly_ordered_along_lineC3(
const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz,
const FT &rx, const FT &ry, const FT &rz)
{
if (px < qx) return (qx < rx);
if (qx < px) return (rx < qx);
if (py < qy) return (qy < ry);
if (qy < py) return (ry < qy);
if (pz < qz) return (qz < rz);
if (qz < pz) return (rz < qz);
return false; // p==q
}
template < class FT >
CGAL_KERNEL_MEDIUM_INLINE
bool
equal_directionC3(const FT &dx1, const FT &dy1, const FT &dz1,
const FT &dx2, const FT &dy2, const FT &dz2)
{
return sign_of_determinant2x2(dx1, dy1, dx2, dy2) == ZERO
&& sign_of_determinant2x2(dx1, dz1, dx2, dz2) == ZERO
&& sign_of_determinant2x2(dy1, dz1, dy2, dz2) == ZERO
&& CGAL_NTS sign(dx1) == CGAL_NTS sign(dx2)
&& CGAL_NTS sign(dy1) == CGAL_NTS sign(dy2)
&& CGAL_NTS sign(dz1) == CGAL_NTS sign(dz2);
}
template <class FT >
CGAL_KERNEL_LARGE_INLINE
Oriented_side
side_of_oriented_planeC3(const FT &a, const FT &b, const FT &c, const FT &d,
const FT &px, const FT &py, const FT &pz)
{
return Oriented_side(CGAL_NTS sign(a*px + b*py + c*pz +d));
}
template <class FT >
CGAL_KERNEL_LARGE_INLINE
Oriented_side
side_of_oriented_sphereC3(const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz,
const FT &rx, const FT &ry, const FT &rz,
const FT &sx, const FT &sy, const FT &sz,
const FT &tx, const FT &ty, const FT &tz)
{
FT ptx = px - tx;
FT pty = py - ty;
FT ptz = pz - tz;
FT pt2 = CGAL_NTS square(ptx) + CGAL_NTS square(pty) + CGAL_NTS square(ptz);
FT qtx = qx - tx;
FT qty = qy - ty;
FT qtz = qz - tz;
FT qt2 = CGAL_NTS square(qtx) + CGAL_NTS square(qty) + CGAL_NTS square(qtz);
FT rtx = rx - tx;
FT rty = ry - ty;
FT rtz = rz - tz;
FT rt2 = CGAL_NTS square(rtx) + CGAL_NTS square(rty) + CGAL_NTS square(rtz);
FT stx = sx - tx;
FT sty = sy - ty;
FT stz = sz - tz;
FT st2 = CGAL_NTS square(stx) + CGAL_NTS square(sty) + CGAL_NTS square(stz);
return Oriented_side(sign_of_determinant4x4(ptx,pty,ptz,pt2,
rtx,rty,rtz,rt2,
qtx,qty,qtz,qt2,
stx,sty,stz,st2));
}
template <class FT >
CGAL_KERNEL_MEDIUM_INLINE
Bounded_side
side_of_bounded_sphereC3(const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz,
const FT &rx, const FT &ry, const FT &rz,
const FT &sx, const FT &sy, const FT &sz,
const FT &tx, const FT &ty, const FT &tz)
{
Oriented_side s = side_of_oriented_sphereC3(px, py, pz,
qx, qy, qz,
rx, ry, rz,
sx, sy, sz,
tx, ty, tz);
Orientation o = orientationC3(px, py, pz,
qx, qy, qz,
rx, ry, rz,
sx, sy, sz);
return Bounded_side(s * o);
}
template < class FT >
CGAL_KERNEL_INLINE
Comparison_result
cmp_dist_to_pointC3(const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz,
const FT &rx, const FT &ry, const FT &rz)
{
return CGAL_NTS compare(squared_distanceC3(px,py,pz,qx,qy,qz),
squared_distanceC3(px,py,pz,rx,ry,rz));
}
template < class FT >
/*CGAL_NO_FILTER*/
CGAL_KERNEL_MEDIUM_INLINE
bool
has_larger_dist_to_pointC3(const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz,
const FT &rx, const FT &ry, const FT &rz)
{
return cmp_dist_to_pointC3(px,py,pz,qx,qy,qz,rx,ry,rz) == LARGER;
}
template < class FT >
/*CGAL_NO_FILTER*/
CGAL_KERNEL_MEDIUM_INLINE
bool
has_smaller_dist_to_pointC3(const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz,
const FT &rx, const FT &ry, const FT &rz)
{
return cmp_dist_to_pointC3(px,py,pz,qx,qy,qz,rx,ry,rz) == SMALLER;
}
template < class FT >
CGAL_KERNEL_MEDIUM_INLINE
Comparison_result
cmp_signed_dist_to_directionC3(
const FT &pa, const FT &pb, const FT &pc,
const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz)
{
return CGAL_NTS compare(scaled_distance_to_directionC3(pa,pb,pc,px,py,pz),
scaled_distance_to_directionC3(pa,pb,pc,qx,qy,qz));
}
template < class FT >
/*CGAL_NO_FILTER*/
CGAL_KERNEL_MEDIUM_INLINE
bool
has_larger_signed_dist_to_directionC3(
const FT &pa, const FT &pb, const FT &pc,
const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz)
{
return cmp_signed_dist_to_directionC3(pa,pb,pc,px,py,pz,qx,qy,qz) == LARGER;
}
template < class FT >
/*CGAL_NO_FILTER*/
CGAL_KERNEL_MEDIUM_INLINE
bool
has_smaller_signed_dist_to_directionC3(
const FT &pa, const FT &pb, const FT &pc,
const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz)
{
return cmp_signed_dist_to_directionC3(pa,pb,pc,px,py,pz,qx,qy,qz) == SMALLER;
}
template < class FT >
CGAL_KERNEL_MEDIUM_INLINE
Comparison_result
cmp_signed_dist_to_planeC3(
const FT &ppx, const FT &ppy, const FT &ppz,
const FT &pqx, const FT &pqy, const FT &pqz,
const FT &prx, const FT &pry, const FT &prz,
const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz)
{
return Comparison_result(sign_of_determinant3x3(
pqx-ppx, pqy-ppy, pqz-ppz,
prx-ppx, pry-ppy, prz-ppz,
qx-px, qy-py, qz-pz));
}
template < class FT >
/*CGAL_NO_FILTER*/
CGAL_KERNEL_MEDIUM_INLINE
bool
has_larger_signed_dist_to_planeC3(
const FT &ppx, const FT &ppy, const FT &ppz,
const FT &pqx, const FT &pqy, const FT &pqz,
const FT &prx, const FT &pry, const FT &prz,
const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz)
{
return cmp_signed_dist_to_planeC3(ppx, ppy, ppz, pqx, pqy, pqz,
prx, pry, prz, px, py, pz, qx, qy, qz) == LARGER;
}
template < class FT >
/*CGAL_NO_FILTER*/
CGAL_KERNEL_MEDIUM_INLINE
bool
has_smaller_signed_dist_to_planeC3(
const FT &ppx, const FT &ppy, const FT &ppz,
const FT &pqx, const FT &pqy, const FT &pqz,
const FT &prx, const FT &pry, const FT &prz,
const FT &px, const FT &py, const FT &pz,
const FT &qx, const FT &qy, const FT &qz)
{
return cmp_signed_dist_to_planeC3(ppx, ppy, ppz, pqx, pqy, pqz,
prx, pry, prz, px, py, pz, qx, qy, qz) == SMALLER;
}
CGAL_END_NAMESPACE
#ifdef CGAL_ARITHMETIC_FILTER_H
#include <CGAL/Arithmetic_filter/predicates/kernel_ftC3.h>
#endif
#endif // CGAL_PREDICATES_KERNEL_FTC3_H
| [
"mtcampbe@illinoisrocstar.com"
] | mtcampbe@illinoisrocstar.com |
951af2d8a66b829941b346097e29047768cb2191 | 09d26a821db354a052df22d6d68da522fdd30b79 | /variantdesign/PrtModifyDlg.h | b72845f59686c0497646b836dc234503ebbf494c | [] | no_license | simmon2014/RuiLi | c04fd2e43933650380950111c55e188f5a021a3c | bf20d7344859ad6a1186bf1d37b804d078a6c00f | refs/heads/master | 2020-12-31T07:10:59.554489 | 2017-03-29T12:04:23 | 2017-03-29T12:09:35 | 86,577,100 | 0 | 4 | null | null | null | null | GB18030 | C++ | false | false | 1,022 | h | #pragma once
#include "afxwin.h"
#include "afxcmn.h"
#include "DetailInfoClass.h"
// CPrtModifyDlg 对话框
class CPrtModifyDlg : public CDialog
{
DECLARE_DYNAMIC(CPrtModifyDlg)
public:
CPrtModifyDlg(CWnd* pParent = NULL); // 标准构造函数
virtual ~CPrtModifyDlg();
// 对话框数据
enum { IDD = IDD_DIALOG_PRTMODIFY };
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV 支持
DECLARE_MESSAGE_MAP()
public:
CString m_key;
CComboBox m_combokey;
afx_msg void OnBnClickedButtonQuery();
DetailInfoClass *info;
CTreeCtrl m_treeprt;
CListCtrl m_listprt;
virtual BOOL OnInitDialog();
BOOL GetPrtFromBase(CString sql,BOOL PDM);
afx_msg void OnBnClickedOk();
int m_workspace;
CString InsCode;
int TypeNum;
afx_msg void OnBnClickedRadioPdm();
afx_msg void OnBnClickedRadioWorkapace();
afx_msg void OnNMClickTreePart(NMHDR *pNMHDR, LRESULT *pResult);
BOOL ObtianPartInfByType(int num);
afx_msg void OnMove(int x, int y);
BOOL m_audit;
BOOL OpenPrtFileFromSever();
};
| [
"simmon2014@163.com"
] | simmon2014@163.com |
b6adf9c0e2c96bb64d86bc39eaa02bf114d7d6b4 | e98a1cd9cee64c1957c96ec4a357dd3e6c9c2bb4 | /profile/set_n_get_expose.cpp | ddf9d1fa76bdc8c7818c627cce7bec1bda69c912 | [
"MIT"
] | permissive | coolshuiping/oolua | 1df835d985ef7433a9948544c5b4bafa7014e14a | 437b0911e00ff07b74b93bf115026c688af6f31d | refs/heads/master | 2021-01-10T20:06:49.711326 | 2013-06-14T20:42:31 | 2013-06-14T20:42:31 | 33,646,236 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 973 | cpp | #include "set_n_get_expose.h"
#ifdef OOLUA_LUABIND_COMPARE
# include "luabind/luabind.hpp"
# include "luabind/operator.hpp"
#endif
EXPORT_OOLUA_FUNCTIONS_1_NON_CONST(Set_get,set)
EXPORT_OOLUA_FUNCTIONS_1_CONST(Set_get,get)
void open_Luabind_set_n_get(lua_State *l)
{
#ifdef OOLUA_LUABIND_COMPARE
luabind::open(l);
luabind::module(l)
[
luabind::class_<Set_get>("Set_get")
.def(luabind::constructor<>())
.def("set",&Set_get::set)
.def("get",&Set_get::get)
];
#else
(void)l;
#endif
}
#ifdef OOLUA_LUABRIDGE_COMPARE
# include "LuaBridge.h"
#endif
void open_LuaBridge_set_n_get(lua_State* l)
{
#ifdef OOLUA_LUABRIDGE_COMPARE
typedef void (*default_constructor) (void);
//.addConstructor<default_constructor>()
using namespace luabridge;
getGlobalNamespace(l)
.beginClass <Set_get>("Set_get")
.addConstructor<void(*)(void)>()
.addFunction("set",&Set_get::set)
.addFunction("get",&Set_get::get)
.endClass ();
#else
(void)l;
#endif
}
| [
"liam.list@gmail.com@078c8882-b850-11de-b71e-ab0a53e69959"
] | liam.list@gmail.com@078c8882-b850-11de-b71e-ab0a53e69959 |
4d0b53a482c90dd265b437118ba4418b10d65bdf | 10c14a95421b63a71c7c99adf73e305608c391bf | /gui/painting/qdrawhelper_sse3dnow.cpp | 325071e7a296c7ba53ffb82c3cae7beafa0c42b8 | [] | no_license | eaglezzb/wtlcontrols | 73fccea541c6ef1f6db5600f5f7349f5c5236daa | 61b7fce28df1efe4a1d90c0678ec863b1fd7c81c | refs/heads/master | 2021-01-22T13:47:19.456110 | 2009-05-19T10:58:42 | 2009-05-19T10:58:42 | 33,811,815 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 5,216 | cpp | /****************************************************************************
**
** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
** Contact: Qt Software Information (qt-info@nokia.com)
**
** This file is part of the QtGui module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial Usage
** Licensees holding valid Qt Commercial licenses may use this file in
** accordance with the Qt Commercial License Agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and Nokia.
**
** GNU Lesser General Public License Usage
** Alternatively, this file may be used under the terms of the GNU Lesser
** General Public License version 2.1 as published by the Free Software
** Foundation and appearing in the file LICENSE.LGPL included in the
** packaging of this file. Please review the following information to
** ensure the GNU Lesser General Public License version 2.1 requirements
** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
**
** In addition, as a special exception, Nokia gives you certain
** additional rights. These rights are described in the Nokia Qt LGPL
** Exception version 1.0, included in the file LGPL_EXCEPTION.txt in this
** package.
**
** GNU General Public License Usage
** Alternatively, this file may be used under the terms of the GNU
** General Public License version 3.0 as published by the Free Software
** Foundation and appearing in the file LICENSE.GPL included in the
** packaging of this file. Please review the following information to
** ensure the GNU General Public License version 3.0 requirements will be
** met: http://www.gnu.org/copyleft/gpl.html.
**
** If you are unsure which license is appropriate for your use, please
** contact the sales department at qt-sales@nokia.com.
** $QT_END_LICENSE$
**
****************************************************************************/
#include <private/qdrawhelper_x86_p.h>
#if defined(QT_HAVE_3DNOW) && defined(QT_HAVE_SSE)
#include <private/qdrawhelper_sse_p.h>
#include <mm3dnow.h>
QT_BEGIN_NAMESPACE
struct QSSE3DNOWIntrinsics : public QSSEIntrinsics
{
static inline void end() {
_m_femms();
}
};
CompositionFunctionSolid qt_functionForModeSolid_SSE3DNOW[numCompositionFunctions] = {
comp_func_solid_SourceOver<QSSE3DNOWIntrinsics>,
comp_func_solid_DestinationOver<QSSE3DNOWIntrinsics>,
comp_func_solid_Clear<QSSE3DNOWIntrinsics>,
comp_func_solid_Source<QSSE3DNOWIntrinsics>,
0,
comp_func_solid_SourceIn<QSSE3DNOWIntrinsics>,
comp_func_solid_DestinationIn<QSSE3DNOWIntrinsics>,
comp_func_solid_SourceOut<QSSE3DNOWIntrinsics>,
comp_func_solid_DestinationOut<QSSE3DNOWIntrinsics>,
comp_func_solid_SourceAtop<QSSE3DNOWIntrinsics>,
comp_func_solid_DestinationAtop<QSSE3DNOWIntrinsics>,
comp_func_solid_XOR<QSSE3DNOWIntrinsics>,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // svg 1.2 modes
rasterop_solid_SourceOrDestination<QSSE3DNOWIntrinsics>,
rasterop_solid_SourceAndDestination<QSSE3DNOWIntrinsics>,
rasterop_solid_SourceXorDestination<QSSE3DNOWIntrinsics>,
rasterop_solid_NotSourceAndNotDestination<QSSE3DNOWIntrinsics>,
rasterop_solid_NotSourceOrNotDestination<QSSE3DNOWIntrinsics>,
rasterop_solid_NotSourceXorDestination<QSSE3DNOWIntrinsics>,
rasterop_solid_NotSource<QSSE3DNOWIntrinsics>,
rasterop_solid_NotSourceAndDestination<QSSE3DNOWIntrinsics>,
rasterop_solid_SourceAndNotDestination<QSSE3DNOWIntrinsics>
};
CompositionFunction qt_functionForMode_SSE3DNOW[numCompositionFunctions] = {
comp_func_SourceOver<QSSE3DNOWIntrinsics>,
comp_func_DestinationOver<QSSE3DNOWIntrinsics>,
comp_func_Clear<QSSE3DNOWIntrinsics>,
comp_func_Source<QSSE3DNOWIntrinsics>,
0,
comp_func_SourceIn<QSSE3DNOWIntrinsics>,
comp_func_DestinationIn<QSSE3DNOWIntrinsics>,
comp_func_SourceOut<QSSE3DNOWIntrinsics>,
comp_func_DestinationOut<QSSE3DNOWIntrinsics>,
comp_func_SourceAtop<QSSE3DNOWIntrinsics>,
comp_func_DestinationAtop<QSSE3DNOWIntrinsics>,
comp_func_XOR<QSSE3DNOWIntrinsics>
};
void qt_blend_color_argb_sse3dnow(int count, const QSpan *spans, void *userData)
{
qt_blend_color_argb_x86<QSSE3DNOWIntrinsics>(count, spans, userData,
(CompositionFunctionSolid*)qt_functionForModeSolid_SSE3DNOW);
}
void qt_memfill32_sse3dnow(quint32 *dest, quint32 value, int count)
{
return qt_memfill32_sse_template<QSSE3DNOWIntrinsics>(dest, value, count);
}
void qt_bitmapblit16_sse3dnow(QRasterBuffer *rasterBuffer, int x, int y,
quint32 color,
const uchar *src,
int width, int height, int stride)
{
return qt_bitmapblit16_sse_template<QSSE3DNOWIntrinsics>(rasterBuffer, x,y,
color, src, width,
height, stride);
}
QT_END_NAMESPACE
#endif // QT_HAVE_3DNOW && QT_HAVE_SSE
| [
"zhangyinquan@0feb242a-2539-11de-a0d7-251e5865a1c7"
] | zhangyinquan@0feb242a-2539-11de-a0d7-251e5865a1c7 |
4c35a52742a6d71cc449b9bb30ca38397f951dcb | 560090526e32e009e2e9331e8a2b4f1e7861a5e8 | /Compiled/blaze-3.2/blazetest/blazetest/mathtest/lu/DenseTest.h | cc06b79f6e423f78862ffe84230eb5ef0f618914 | [
"BSD-3-Clause"
] | permissive | jcd1994/MatlabTools | 9a4c1f8190b5ceda102201799cc6c483c0a7b6f7 | 2cc7eac920b8c066338b1a0ac495f0dbdb4c75c1 | refs/heads/master | 2021-01-18T03:05:19.351404 | 2018-02-14T02:17:07 | 2018-02-14T02:17:07 | 84,264,330 | 2 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 8,287 | h | //=================================================================================================
/*!
// \file blazetest/mathtest/lu/DenseTest.h
// \brief Header file for the dense matrix LU test
//
// Copyright (C) 2012-2017 Klaus Iglberger - All Rights Reserved
//
// This file is part of the Blaze library. You can redistribute it and/or modify it under
// the terms of the New (Revised) BSD License. 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 names of the Blaze development group 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 _BLAZETEST_MATHTEST_LU_DENSETEST_H_
#define _BLAZETEST_MATHTEST_LU_DENSETEST_H_
//*************************************************************************************************
// Includes
//*************************************************************************************************
#include <sstream>
#include <stdexcept>
#include <string>
#include <typeinfo>
#include <blaze/math/Aliases.h>
#include <blaze/math/typetraits/IsRowMajorMatrix.h>
#include <blaze/math/typetraits/IsSquare.h>
#include <blaze/math/typetraits/RemoveAdaptor.h>
#include <blaze/util/Complex.h>
#include <blaze/util/Random.h>
#include <blazetest/system/LAPACK.h>
namespace blazetest {
namespace mathtest {
namespace lu {
//=================================================================================================
//
// CLASS DEFINITION
//
//=================================================================================================
//*************************************************************************************************
/*!\brief Auxiliary class for all dense matrix LU tests.
//
// This class represents a test suite for the dense matrix LU decomposition functionality. It
// performs a series of LU decompositions on all dense matrix types of the Blaze library.
*/
class DenseTest
{
public:
//**Constructors********************************************************************************
/*!\name Constructors */
//@{
explicit DenseTest();
// No explicitly declared copy constructor.
//@}
//**********************************************************************************************
//**Destructor**********************************************************************************
// No explicitly declared destructor.
//**********************************************************************************************
private:
//**Test functions******************************************************************************
/*!\name Test functions */
//@{
template< typename Type >
void testRandom();
void testGeneral();
void testSymmetric();
void testHermitian();
void testLower();
void testUniLower();
void testUpper();
void testUniUpper();
void testDiagonal();
//@}
//**********************************************************************************************
//**Type definitions****************************************************************************
typedef blaze::complex<float> cfloat; //!< Single precision complex test type.
typedef blaze::complex<double> cdouble; //!< Double precision complex test type.
//**********************************************************************************************
//**Member variables****************************************************************************
/*!\name Member variables */
//@{
std::string test_; //!< Label of the currently performed test.
//@}
//**********************************************************************************************
};
//*************************************************************************************************
//=================================================================================================
//
// TEST FUNCTIONS
//
//=================================================================================================
//*************************************************************************************************
/*!\brief Test of the LU decomposition with a randomly initialized matrix of the given type.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function tests the dense matrix LU decomposition for a randomly initialized matrix of the
// given type. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
template< typename Type >
void DenseTest::testRandom()
{
#if BLAZETEST_MATHTEST_LAPACK_MODE
test_ = "LU decomposition";
typedef blaze::RemoveAdaptor_<Type> MT;
const size_t m( blaze::rand<size_t>( 3UL, 8UL ) );
const size_t n( blaze::IsSquare<Type>::value ? m : blaze::rand<size_t>( 3UL, 8UL ) );
Type A;
MT L, U, P;
resize( A, m, n );
randomize( A );
blaze::lu( A, L, U, P );
MT LU( L*U );
if( blaze::IsRowMajorMatrix<Type>::value ) {
LU = LU * P;
}
else {
LU = P * LU;
}
if( LU != A ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: LU decomposition failed\n"
<< " Details:\n"
<< " Matrix type:\n"
<< " " << typeid( Type ).name() << "\n"
<< " Element type:\n"
<< " " << typeid( blaze::ElementType_<Type> ).name() << "\n"
<< " Result:\n" << LU << "\n"
<< " Expected result:\n" << A << "\n";
throw std::runtime_error( oss.str() );
}
#endif
}
//*************************************************************************************************
//=================================================================================================
//
// GLOBAL TEST FUNCTIONS
//
//=================================================================================================
//*************************************************************************************************
/*!\brief Testing the dense matrix LU decomposition.
//
// \return void
*/
void runTest()
{
DenseTest();
}
//*************************************************************************************************
//=================================================================================================
//
// MACRO DEFINITIONS
//
//=================================================================================================
//*************************************************************************************************
/*! \cond BLAZE_INTERNAL */
/*!\brief Macro for the execution of the dense matrix LU test.
*/
#define RUN_DENSE_LU_TEST \
blazetest::mathtest::lu::runTest()
/*! \endcond */
//*************************************************************************************************
} // namespace lu
} // namespace mathtest
} // namespace blazetest
#endif
| [
"jonathan.doucette@alumni.ubc.ca"
] | jonathan.doucette@alumni.ubc.ca |
8d441eeb8fb17cad740a56f9ae22d2fcb1362268 | ab08dcb1f06ab70edd174d6b72e38f90180e22ac | /SDK/imgui_master/examples/example_freeglut_opengl2/main.cpp | d57ee07f0cc2fb0759adbf980832fce30da97a32 | [
"MIT"
] | permissive | AngelMonica126/GraphicAlgorithm | f208bbbe0212151a2659b425816380d9f9dbdd8a | 58877e6a8dba75ab171b0d89260defaffa22d047 | refs/heads/master | 2022-06-02T18:46:36.061487 | 2022-03-06T14:30:44 | 2022-03-06T14:30:44 | 271,798,397 | 1,240 | 203 | MIT | 2021-08-19T07:32:05 | 2020-06-12T12:55:47 | C++ | UTF-8 | C++ | false | false | 6,217 | cpp | // dear imgui: standalone example application for FreeGLUT + OpenGL2, using legacy fixed pipeline
// If you are new to dear imgui, see examples/README.txt and documentation at the top of imgui.cpp.
// (Using GLUT or FreeGLUT is not recommended unless you really miss the 90's)
#include "imgui.h"
#include "../imgui_impl_freeglut.h"
#include "../imgui_impl_opengl2.h"
#include <GL/freeglut.h>
#ifdef _MSC_VER
#pragma warning (disable: 4505) // unreferenced local function has been removed
#endif
static bool show_demo_window = true;
static bool show_another_window = false;
static ImVec4 clear_color = ImVec4(0.45f, 0.55f, 0.60f, 1.00f);
void my_display_code()
{
// 1. Show the big demo window (Most of the sample code is in ImGui::ShowDemoWindow()! You can browse its code to learn more about Dear ImGui!).
if (show_demo_window)
ImGui::ShowDemoWindow(&show_demo_window);
// 2. Show a simple window that we create ourselves. We use a Begin/End pair to created a named window.
{
static float f = 0.0f;
static int counter = 0;
ImGui::Begin("Hello, world!"); // Create a window called "Hello, world!" and append into it.
ImGui::Text("This is some useful text."); // Display some text (you can use a format strings too)
ImGui::Checkbox("Demo Window", &show_demo_window); // Edit bools storing our window open/close state
ImGui::Checkbox("Another Window", &show_another_window);
ImGui::SliderFloat("float", &f, 0.0f, 1.0f); // Edit 1 float using a slider from 0.0f to 1.0f
ImGui::ColorEdit3("clear color", (float*)&clear_color); // Edit 3 floats representing a color
if (ImGui::Button("Button")) // Buttons return true when clicked (most widgets return true when edited/activated)
counter++;
ImGui::SameLine();
ImGui::Text("counter = %d", counter);
ImGui::Text("Application average %.3f ms/frame (%.1f FPS)", 1000.0f / ImGui::GetIO().Framerate, ImGui::GetIO().Framerate);
ImGui::End();
}
// 3. Show another simple window.
if (show_another_window)
{
ImGui::Begin("Another Window", &show_another_window); // Pass a pointer to our bool variable (the window will have a closing button that will clear the bool when clicked)
ImGui::Text("Hello from another window!");
if (ImGui::Button("Close Me"))
show_another_window = false;
ImGui::End();
}
}
void glut_display_func()
{
// Start the Dear ImGui frame
ImGui_ImplOpenGL2_NewFrame();
ImGui_ImplFreeGLUT_NewFrame();
my_display_code();
// Rendering
ImGui::Render();
ImGuiIO& io = ImGui::GetIO();
glViewport(0, 0, (GLsizei)io.DisplaySize.x, (GLsizei)io.DisplaySize.y);
glClearColor(clear_color.x, clear_color.y, clear_color.z, clear_color.w);
glClear(GL_COLOR_BUFFER_BIT);
//glUseProgram(0); // You may want this if using this code in an OpenGL 3+ context where shaders may be bound, but prefer using the GL3+ code.
ImGui_ImplOpenGL2_RenderDrawData(ImGui::GetDrawData());
glutSwapBuffers();
glutPostRedisplay();
}
// You can read the io.WantCaptureMouse, io.WantCaptureKeyboard flags to tell if dear imgui wants to use your inputs.
// - When io.WantCaptureMouse is true, do not dispatch mouse input data to your main application.
// - When io.WantCaptureKeyboard is true, do not dispatch keyboard input data to your main application.
// Generally you may always pass all inputs to dear imgui, and hide them from your application based on those two flags.
int main(int argc, char** argv)
{
// Create GLUT window
glutInit(&argc, argv);
glutSetOption(GLUT_ACTION_ON_WINDOW_CLOSE, GLUT_ACTION_GLUTMAINLOOP_RETURNS);
glutInitDisplayMode(GLUT_RGBA | GLUT_DOUBLE | GLUT_MULTISAMPLE);
glutInitWindowSize(1280, 720);
glutCreateWindow("Dear ImGui FreeGLUT+OpenGL2 Example");
// Setup GLUT display function
// We will also call ImGui_ImplFreeGLUT_InstallFuncs() to get all the other functions installed for us,
// otherwise it is possible to install our own functions and call the imgui_impl_freeglut.h functions ourselves.
glutDisplayFunc(glut_display_func);
// Setup Dear ImGui binding
ImGui::CreateContext();
ImGuiIO& io = ImGui::GetIO(); (void)io;
//io.ConfigFlags |= ImGuiConfigFlags_NavEnableKeyboard; // Enable Keyboard Controls
ImGui_ImplFreeGLUT_Init();
ImGui_ImplFreeGLUT_InstallFuncs();
ImGui_ImplOpenGL2_Init();
// Setup style
ImGui::StyleColorsDark();
//ImGui::StyleColorsClassic();
// Load Fonts
// - If no fonts are loaded, dear imgui will use the default font. You can also load multiple fonts and use ImGui::PushFont()/PopFont() to select them.
// - AddFontFromFileTTF() will return the ImFont* so you can store it if you need to select the font among multiple.
// - If the file cannot be loaded, the function will return NULL. Please handle those errors in your application (e.g. use an assertion, or display an error and quit).
// - The fonts will be rasterized at a given size (w/ oversampling) and stored into a texture when calling ImFontAtlas::Build()/GetTexDataAsXXXX(), which ImGui_ImplXXXX_NewFrame below will call.
// - Read 'misc/fonts/README.txt' for more instructions and details.
// - Remember that in C/C++ if you want to include a backslash \ in a string literal you need to write a double backslash \\ !
//io.Fonts->AddFontDefault();
//io.Fonts->AddFontFromFileTTF("../../misc/fonts/Roboto-Medium.ttf", 16.0f);
//io.Fonts->AddFontFromFileTTF("../../misc/fonts/Cousine-Regular.ttf", 15.0f);
//io.Fonts->AddFontFromFileTTF("../../misc/fonts/DroidSans.ttf", 16.0f);
//io.Fonts->AddFontFromFileTTF("../../misc/fonts/ProggyTiny.ttf", 10.0f);
//ImFont* font = io.Fonts->AddFontFromFileTTF("c:\\Windows\\Fonts\\ArialUni.ttf", 18.0f, NULL, io.Fonts->GetGlyphRangesJapanese());
//IM_ASSERT(font != NULL);
glutMainLoop();
// Cleanup
ImGui_ImplOpenGL2_Shutdown();
ImGui_ImplFreeGLUT_Shutdown();
ImGui::DestroyContext();
return 0;
}
| [
"vailing817@gmail.com"
] | vailing817@gmail.com |
dd217fe56d596365fb9539376036f9076a49d049 | da8a9560ad2eda67e586c47af32a8efd3fc8f423 | /LB_code/WhileLoop_Advanced1.cpp | 318d5ef926f5a9e5828270f4666d6d94cb7972a8 | [] | no_license | Kwadders/LB_code | 254c3d12b72ff34e88867e50ece29655e6167f82 | db269585afa41247cc34cc4ae55bfcd3cc4b839c | refs/heads/master | 2016-09-05T22:24:57.576149 | 2014-02-19T10:26:11 | 2014-02-19T10:26:11 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,262 | cpp | #include <iostream>
using namespace std;
/****************************************************************
*Author: Lewis Bucke *
*Date: 30th April 2013 *
*Description: Function to output "HellowWorld" a number of *
times defined by i *
*****************************************************************/
int main()
{
//Lewi's first CPP code this code is used to repeat helo world 5 times
int i; //Declare counting variable
i = 10; //Initialise the variable
while(i)
{
/*Print "Hello World" for values 10-5
Print "Bye Bye world" for values 5-0*/
if((i<=10)&&(i>5))
{
cout << "Hello world" <<endl; // this is what it says it also counts how much it repeats
}
else
//if(i<=5) //we do not need this because change the logic so we can, potentially, save some bytes
{
cout << "Bye Bye World"<<endl; //Print out values when i less than 5#include <iostream>
}
i--;
}
return 0;
}
| [
"kwadwo@debian.home"
] | kwadwo@debian.home |
d52b8602c31f0e5dd01d7ccbdf18720beace32ce | 549a402538164fb88a2711ae1454f413127630c6 | /src/ControlBar.cpp | 900d545c1be52b0dbc56e1168abf81a21aa425c9 | [] | no_license | vilhelmo/orka | f06c6e9f4c49ec50af2d2c993585ba54b323e83c | 6ba56cf74742b32ea0913dc1b4edc7e1452cd38a | refs/heads/master | 2016-08-04T01:24:24.839916 | 2014-01-12T08:59:48 | 2014-01-12T08:59:48 | 10,898,266 | 0 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 3,316 | cpp | /*
* ControlBar.cpp
*
* Created on: Dec 27, 2013
* Author: vilhelm
*/
#include "ControlBar.h"
#include <QLayout>
#include <QLabel>
#include <QPushButton>
#include <QHBoxLayout>
#include <QIcon>
#include <utility>
#include <iostream>
#include "ImageProvider.h"
namespace orka {
ControlBar::ControlBar(QWidget * parent) :
QWidget(parent), image_provider_(NULL), slider_moving_(false) {
QHBoxLayout * layout = new QHBoxLayout(this);
this->setLayout(layout);
first_frame_button_ = new QPushButton(QIcon("media-skip-backward.png"), "");
stop_button_ = new QPushButton(QIcon("media-playback-stop.png"), "");
start_button_ = new QPushButton(QIcon("media-playback-start.png"), "");
last_frame_button_ = new QPushButton(QIcon("media-skip-forward.png"), "");
first_frame_button_->setFlat(true);
stop_button_->setFlat(true);
start_button_->setFlat(true);
last_frame_button_->setFlat(true);
frame_slider_ = new QSlider(Qt::Horizontal);
layout->addWidget(first_frame_button_);
layout->addWidget(stop_button_);
layout->addWidget(start_button_);
layout->addWidget(last_frame_button_);
layout->addWidget(frame_slider_);
frame_slider_->setMinimum(1);
frame_slider_->setMaximum(100);
frame_slider_->setSingleStep(1);
frame_slider_->setPageStep(1);
frame_slider_->setSliderPosition(1);
this->setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Minimum);
}
ControlBar::~ControlBar() {
delete first_frame_button_;
delete stop_button_;
delete start_button_;
delete last_frame_button_;
delete frame_slider_;
}
void ControlBar::sliderPressed() {
slider_moving_ = true;
}
void ControlBar::sliderReleased() {
slider_moving_ = false;
}
void ControlBar::set_image_provider(ImageProvider * provider) {
image_provider_ = provider;
std::pair<int, int> framerange = image_provider_->getFramerange();
frame_slider_->setMinimum(framerange.first);
frame_slider_->setMaximum(framerange.second);
frame_slider_->setSliderPosition(framerange.first);
QObject::connect(frame_slider_, SIGNAL(sliderMoved(int)), this,
SLOT(frameChanged(int)));
QObject::connect(frame_slider_, SIGNAL(sliderPressed()), this,
SLOT(sliderPressed()));
QObject::connect(frame_slider_, SIGNAL(sliderReleased()), this,
SLOT(sliderReleased()));
QObject::connect(stop_button_, SIGNAL(clicked(bool)), image_provider_,
SLOT(stop()));
QObject::connect(start_button_, SIGNAL(clicked(bool)), image_provider_,
SLOT(start()));
QObject::connect(first_frame_button_, SIGNAL(clicked(bool)), this,
SLOT(gotoFirstFrame()));
QObject::connect(last_frame_button_, SIGNAL(clicked(bool)), this,
SLOT(gotoLastFrame()));
}
void ControlBar::displayImage(OrkaImage * image, int frame, bool freeOldImageData) {
if (!slider_moving_) {
frame_slider_->setSliderPosition(frame);
}
}
void ControlBar::gotoFirstFrame() {
image_provider_->gotoFrame(image_provider_->getFramerange().first);
}
void ControlBar::gotoLastFrame() {
image_provider_->gotoFrame(image_provider_->getFramerange().second);
}
void ControlBar::frameChanged(int frame) {
image_provider_->gotoFrame(frame);
}
} /* namespace orka */
| [
"vilhelmo@gmail.com"
] | vilhelmo@gmail.com |
802a3e42e5f4b98b5205d6948b7a201896d611a1 | 1a2752708cfa58fc70cb76fcfdf061576c722c97 | /src/DesignSpaceHelper/SortListCtrl.cpp | 76da30e49edc1d674f2d51b6c65e0bd0d442a915 | [
"LicenseRef-scancode-other-permissive"
] | permissive | dyao-vu/meta-core | 7adf67093303288f1875a819ad1f4d9bfb00cd53 | 54a67c9ab3eb569545724c10909f436c0770da7d | refs/heads/master | 2020-04-07T05:54:27.154716 | 2017-02-09T18:33:25 | 2017-02-09T18:35:38 | 57,243,888 | 0 | 0 | null | 2016-04-27T20:01:12 | 2016-04-27T20:01:12 | null | UTF-8 | C++ | false | false | 12,743 | cpp | /*----------------------------------------------------------------------
Copyright (C)2001 MJSoft. All Rights Reserved.
This source may be used freely as long as it is not sold for
profit and this copyright information is not altered or removed.
Visit the web-site at www.mjsoft.co.uk
e-mail comments to info@mjsoft.co.uk
File: SortListCtrl.cpp
Purpose: Provides a sortable list control, it will sort text, numbers
and dates, ascending or descending, and will even draw the
arrows just like windows explorer!
----------------------------------------------------------------------*/
#include "StdAfx.h"
#include "SortListCtrl.h"
#include "resource.h"
#include "ConstraintMainDialog.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
LPCTSTR g_pszSection = _T("ListCtrls");
struct ItemData
{
public:
ItemData() : arrpsz( NULL ), dwData( NULL ) {}
LPTSTR* arrpsz;
DWORD dwData;
int uid;
private:
// ban copying.
ItemData( const ItemData& );
ItemData& operator=( const ItemData& );
};
CSortListCtrl::CSortListCtrl()
: m_iNumColumns( 0 )
, m_iSortColumn( -1 )
, m_bSortAscending( TRUE )
, m_showInfoTip( TRUE )
{
}
CSortListCtrl::~CSortListCtrl()
{
if(!m_pwchTip)
delete m_pwchTip;
}
void CSortListCtrl::SetColumnNum(int numColumns)
{
m_iNumColumns = numColumns;
}
BEGIN_MESSAGE_MAP(CSortListCtrl, CListCtrl)
//{{AFX_MSG_MAP(CSortListCtrl)
ON_NOTIFY_REFLECT(LVN_COLUMNCLICK, OnColumnClick)
// ON_NOTIFY_EX(TTN_NEEDTEXTA, 0, OnToolNeedText)
ON_NOTIFY_EX(TTN_NEEDTEXTW, 0, OnToolNeedText)
ON_WM_DESTROY()
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CSortListCtrl message handlers
void CSortListCtrl::PreSubclassWindow()
{
// the list control must have the report style.
ASSERT( GetStyle() & LVS_REPORT );
CListCtrl::PreSubclassWindow();
#if (_WIN32_WINNT >= 0x501)
SetExtendedStyle(LVS_EX_DOUBLEBUFFER | GetExtendedStyle());
#endif
SetExtendedStyle(GetExtendedStyle() | LVS_EX_FULLROWSELECT);
SetExtendedStyle(GetExtendedStyle() | LVS_EX_HEADERDRAGDROP);
SetExtendedStyle(GetExtendedStyle() | LVS_EX_GRIDLINES);
VERIFY( m_ctlHeader.SubclassWindow( GetHeaderCtrl()->GetSafeHwnd() ) );
}
BOOL CSortListCtrl::initHeadListCtr(BOOL showHeadCheckBox)
{
m_ctlHeader.SetHeadCheckBox(showHeadCheckBox);
if(!showHeadCheckBox) return TRUE;
CHeaderCtrl* pHeadCtrl = GetHeaderCtrl();
ASSERT(pHeadCtrl->GetSafeHwnd());
// VERIFY( m_ctlHeader.SubclassWindow( GetHeaderCtrl()->GetSafeHwnd() ) );
VERIFY( m_checkImgList.Create(IDB_CHECKBOXES, 16, 3, RGB(255,0,255)) );
int i = m_checkImgList.GetImageCount();
m_ctlHeader.SetImageList(&m_checkImgList);
HDITEM hdItem;
hdItem.mask = HDI_IMAGE | HDI_FORMAT;
VERIFY( m_ctlHeader.GetItem(0, &hdItem) );
hdItem.iImage = 1;
hdItem.fmt |= HDF_IMAGE;
VERIFY( m_ctlHeader.SetItem(0, &hdItem) );
return TRUE;
}
BOOL CSortListCtrl::SetHeadings( UINT uiStringID )
{
CString strHeadings;
VERIFY( strHeadings.LoadString( uiStringID ) );
return SetHeadings( strHeadings );
}
// the heading text is in the format column 1 text,column 1 width;column 2 text,column 3 width;etc.
BOOL CSortListCtrl::SetHeadings( const CString& strHeadings )
{
int iStart = 0;
for( ;; )
{
const int iComma = strHeadings.Find( _T(','), iStart );
if( iComma == -1 )
break;
const CString strHeading = strHeadings.Mid( iStart, iComma - iStart );
iStart = iComma + 1;
int iSemiColon = strHeadings.Find( _T(';'), iStart );
if( iSemiColon == -1 )
iSemiColon = strHeadings.GetLength();
const int iWidth = _ttoi( strHeadings.Mid( iStart, iSemiColon - iStart ) );
iStart = iSemiColon + 1;
if( InsertColumn( m_iNumColumns++, strHeading, LVCFMT_LEFT, iWidth ) == -1 )
return FALSE;
}
return TRUE;
}
int CSortListCtrl::AddItem(int id, LPCTSTR pszText, ... )
{
const int iIndex = InsertItem( GetItemCount(), pszText );
LPTSTR* arrpsz = new LPTSTR[ m_iNumColumns ];
arrpsz[ 0 ] = new TCHAR[ lstrlen( pszText ) + 1 ];
(void)lstrcpy( arrpsz[ 0 ], pszText );
va_list list;
va_start( list, pszText );
for( int iColumn = 1; iColumn < m_iNumColumns; iColumn++ )
{
pszText = va_arg( list, LPCTSTR );
ASSERT_VALID_STRING( pszText );
VERIFY( CListCtrl::SetItem( iIndex, iColumn, LVIF_TEXT, pszText, 0, 0, 0, 0 ) );
arrpsz[ iColumn ] = new TCHAR[ lstrlen( pszText ) + 1 ];
(void)lstrcpy( arrpsz[ iColumn ], pszText );
}
va_end( list );
VERIFY( SetTextArray( iIndex, arrpsz, id ) );
return iIndex;
}
void CSortListCtrl::FreeItemMemory( const int iItem )
{
ItemData* pid = reinterpret_cast<ItemData*>( CListCtrl::GetItemData( iItem ) );
LPTSTR* arrpsz = pid->arrpsz;
for( int i = 0; i < m_iNumColumns; i++ )
delete[] arrpsz[ i ];
delete[] arrpsz;
delete pid;
VERIFY( CListCtrl::SetItemData( iItem, NULL ) );
}
BOOL CSortListCtrl::DeleteItem( int iItem )
{
FreeItemMemory( iItem );
return CListCtrl::DeleteItem( iItem );
}
BOOL CSortListCtrl::DeleteAllItems()
{
for( int iItem = 0; iItem < GetItemCount(); iItem ++ )
FreeItemMemory( iItem );
return CListCtrl::DeleteAllItems();
}
bool IsNumber( LPCTSTR pszText )
{
ASSERT_VALID_STRING( pszText );
for( int i = 0; i < lstrlen( pszText ); i++ ) {
if( !_istdigit( pszText[ i ] ) ) {
return false;
}
}
return true;
}
int NumberCompare( LPCTSTR pszNumber1, LPCTSTR pszNumber2 )
{
ASSERT_VALID_STRING( pszNumber1 );
ASSERT_VALID_STRING( pszNumber2 );
const int iNumber1 = _ttoi( pszNumber1 );
const int iNumber2 = _ttoi( pszNumber2 );
if( iNumber1 < iNumber2 ) {
return -1;
}
if( iNumber1 > iNumber2 ) {
return 1;
}
return 0;
}
int CALLBACK CSortListCtrl::CompareFunction( LPARAM lParam1, LPARAM lParam2, LPARAM lParamData )
{
CSortListCtrl* pListCtrl = reinterpret_cast<CSortListCtrl*>( lParamData );
ASSERT( pListCtrl->IsKindOf( RUNTIME_CLASS( CListCtrl ) ) );
ItemData* pid1 = reinterpret_cast<ItemData*>( lParam1 );
ItemData* pid2 = reinterpret_cast<ItemData*>( lParam2 );
ASSERT( pid1 );
ASSERT( pid2 );
LPCTSTR pszText1 = pid1->arrpsz[ pListCtrl->m_iSortColumn ];
LPCTSTR pszText2 = pid2->arrpsz[ pListCtrl->m_iSortColumn ];
ASSERT_VALID_STRING( pszText1 );
ASSERT_VALID_STRING( pszText2 );
if( IsNumber( pszText1 ) && IsNumber( pszText2 ))
return pListCtrl->m_bSortAscending ? NumberCompare( pszText1, pszText2 ) : NumberCompare( pszText2, pszText1 );
else
// text.
return pListCtrl->m_bSortAscending ? lstrcmp( pszText1, pszText2 ) : lstrcmp( pszText2, pszText1 );
}
void CSortListCtrl::OnColumnClick( NMHDR* pNMHDR, LRESULT* pResult )
{
NM_LISTVIEW* pNMListView = (NM_LISTVIEW*)pNMHDR;
const int iColumn = pNMListView->iSubItem;
// if it's a second click on the same column then reverse the sort order,
// otherwise sort the new column in ascending order.
if(iColumn!=0)
Sort( iColumn, iColumn == m_iSortColumn ? !m_bSortAscending : TRUE );
*pResult = 0;
}
void CSortListCtrl::Sort( int iColumn, BOOL bAscending )
{
m_iSortColumn = iColumn;
m_bSortAscending = bAscending;
// show the appropriate arrow in the header control.
// m_ctlHeader.SetSortArrow( m_iSortColumn, m_bSortAscending );
VERIFY( SortItems( CompareFunction, reinterpret_cast<DWORD>( this ) ) );
}
void CSortListCtrl::Sort()
{
if(m_iSortColumn<=0)
return;
// m_ctlHeader.SetSortArrow( m_iSortColumn, m_bSortAscending );
VERIFY( SortItems( CompareFunction, reinterpret_cast<DWORD>( this ) ) );
}
void CSortListCtrl::LoadColumnInfo()
{
// you must call this after setting the column headings.
ASSERT( m_iNumColumns > 0 );
CString strKey;
strKey.Format( _T("%d"), GetDlgCtrlID() );
UINT nBytes = 0;
BYTE* buf = NULL;
if( AfxGetApp()->GetProfileBinary( g_pszSection, strKey, &buf, &nBytes ) )
{
if( nBytes > 0 )
{
CMemFile memFile( buf, nBytes );
CArchive ar( &memFile, CArchive::load );
m_ctlHeader.Serialize( ar );
ar.Close();
m_ctlHeader.Invalidate();
}
delete[] buf;
}
}
void CSortListCtrl::SaveColumnInfo()
{
ASSERT( m_iNumColumns > 0 );
CString strKey;
strKey.Format( _T("%d"), GetDlgCtrlID() );
CMemFile memFile;
CArchive ar( &memFile, CArchive::store );
m_ctlHeader.Serialize( ar );
ar.Close();
DWORD dwLen = memFile.GetLength();
BYTE* buf = memFile.Detach();
VERIFY( AfxGetApp()->WriteProfileBinary( g_pszSection, strKey, buf, dwLen ) );
free( buf );
}
void CSortListCtrl::OnDestroy()
{
for( int iItem = 0; iItem < GetItemCount(); iItem ++ )
FreeItemMemory( iItem );
CListCtrl::OnDestroy();
}
BOOL CSortListCtrl::SetItemText( int nItem, int nSubItem, LPCTSTR lpszText )
{
if( !CListCtrl::SetItemText( nItem, nSubItem, lpszText ) )
return FALSE;
LPTSTR* arrpsz = GetTextArray( nItem );
LPTSTR pszText = arrpsz[ nSubItem ];
delete[] pszText;
pszText = new TCHAR[ lstrlen( lpszText ) + 1 ];
(void)lstrcpy( pszText, lpszText );
arrpsz[ nSubItem ] = pszText;
return TRUE;
}
BOOL CSortListCtrl::SetItemData( int nItem, DWORD dwData )
{
if( nItem >= GetItemCount() )
return FALSE;
ItemData* pid = reinterpret_cast<ItemData*>( CListCtrl::GetItemData( nItem ) );
ASSERT( pid );
pid->dwData = dwData;
return TRUE;
}
DWORD CSortListCtrl::GetItemData( int nItem ) const
{
ASSERT( nItem < GetItemCount() );
ItemData* pid = reinterpret_cast<ItemData*>( CListCtrl::GetItemData( nItem ) );
ASSERT( pid );
return pid->dwData;
}
BOOL CSortListCtrl::SetTextArray( int iItem, LPTSTR* arrpsz, int id )
{
ASSERT( CListCtrl::GetItemData( iItem ) == NULL );
ItemData* pid = new ItemData;
pid->arrpsz = arrpsz;
pid->uid = id;
return CListCtrl::SetItemData( iItem, reinterpret_cast<DWORD>( pid ) );
}
LPTSTR* CSortListCtrl::GetTextArray( int iItem ) const
{
ASSERT( iItem < GetItemCount() );
ItemData* pid = reinterpret_cast<ItemData*>( CListCtrl::GetItemData( iItem ) );
return pid->arrpsz;
}
int CSortListCtrl::GetItemID(int nItem)
{
ItemData* pid = reinterpret_cast<ItemData*>( CListCtrl::GetItemData(nItem) );
return pid->uid;
}
void CSortListCtrl::CellHitTest(const CPoint& pt, int& nRow, int& nCol) const
{
nRow = -1;
nCol = -1;
LVHITTESTINFO lvhti = {0};
lvhti.pt = pt;
nRow = ListView_SubItemHitTest(m_hWnd, &lvhti); // SubItemHitTest is non-const
nCol = lvhti.iSubItem;
if (!(lvhti.flags & LVHT_ONITEMLABEL))
nRow = -1;
}
BOOL CSortListCtrl::OnToolNeedText(UINT id, NMHDR* pNMHDR, LRESULT* pResult)
{
CPoint pt(GetMessagePos());
ScreenToClient(&pt);
int nRow, nCol;
CellHitTest(pt, nRow, nCol);
CString tooltip = GetToolTipText(nRow, nCol);
if (tooltip.IsEmpty())
return FALSE;
// Non-unicode applications can receive requests for tooltip-text in unicode
TOOLTIPTEXTW* pTTTW = (TOOLTIPTEXTW*)pNMHDR;
if(!m_pwchTip)
delete m_pwchTip;
m_pwchTip = tooltip;
//get the maxwidth for the tooltip
int maxwidth = 0;
CString tmp = tooltip;
int newline = tmp.Find('\n');
while(newline > 0 && tmp.GetLength()>1)
{
if(newline>maxwidth)
maxwidth = newline;
tmp = tmp.Right(tmp.GetLength()-newline);
newline = tmp.Find('\n');
}
if(tmp.GetLength()>maxwidth)
maxwidth = tmp.GetLength();
::SendMessage(pNMHDR->hwndFrom, TTM_SETMAXTIPWIDTH, 0, maxwidth*6);
pTTTW->lpszText = const_cast<LPTSTR>((const WCHAR*)m_pwchTip);
// If wanting to display a tooltip which is longer than 80 characters,
// then one must allocate the needed text-buffer instead of using szText,
// and point the TOOLTIPTEXT::lpszText to this text-buffer.
// When doing this, then one is required to release this text-buffer again
return TRUE;
}
bool CSortListCtrl::ShowToolTip(const CPoint& pt) const
{
// Lookup up the cell
int nRow, nCol;
CellHitTest(pt, nRow, nCol);
if (nRow!=-1 && nCol!=-1)
return true;
else
return false;
}
CString CSortListCtrl::GetToolTipText(int nRow, int nCol)
{
if (!m_showInfoTip)
return CString("");
if (nRow!=-1 && nCol==1)
{
int i = GetItemID(nRow);
map<int, std::string>::iterator pos = CConstraintMainDialog::constraintExprMap.find(i);
if(pos!=CConstraintMainDialog::constraintExprMap.end())
return (LPSTR)(CConstraintMainDialog::constraintExprMap[i].c_str());
else
return CString("");
}
else
return CString("");
}
| [
"kevin.m.smyth@gmail.com"
] | kevin.m.smyth@gmail.com |
f520746bb9ae7faabdead251ae01231f61361c56 | 1bf8b46afad5402fe6fa74293b464e1ca5ee5fd7 | /Demo/Shenmue3SDK/SDK/BP_AnimNotify_RequestAnimation_functions.cpp | e95b9fdcdbad4406fded728b1c3f04d32bc93f35 | [] | no_license | LemonHaze420/ShenmueIIISDK | a4857eebefc7e66dba9f667efa43301c5efcdb62 | 47a433b5e94f171bbf5256e3ff4471dcec2c7d7e | refs/heads/master | 2021-06-30T17:33:06.034662 | 2021-01-19T20:33:33 | 2021-01-19T20:33:33 | 214,824,713 | 4 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,184 | cpp |
#include "../SDK.h"
// Name: S3Demo, Version: 0.90.0
#ifdef _MSC_VER
#pragma pack(push, 0x8)
#endif
namespace SDK
{
//---------------------------------------------------------------------------
// Functions
//---------------------------------------------------------------------------
// Function BP_AnimNotify_RequestAnimation.BP_AnimNotify_RequestAnimation_C.GetNotifyName
// (Event, Public, HasOutParms, BlueprintCallable, BlueprintEvent, Const)
// Parameters:
// struct FString ReturnValue (Parm, OutParm, ZeroConstructor, ReturnParm)
struct FString UBP_AnimNotify_RequestAnimation_C::GetNotifyName()
{
static auto fn = UObject::FindObject<UFunction>("Function BP_AnimNotify_RequestAnimation.BP_AnimNotify_RequestAnimation_C.GetNotifyName");
UBP_AnimNotify_RequestAnimation_C_GetNotifyName_Params params;
auto flags = fn->FunctionFlags;
UObject::ProcessEvent(fn, ¶ms);
fn->FunctionFlags = flags;
return params.ReturnValue;
}
// Function BP_AnimNotify_RequestAnimation.BP_AnimNotify_RequestAnimation_C.Received_Notify
// (Event, Public, HasOutParms, BlueprintCallable, BlueprintEvent, Const)
// Parameters:
// class USkeletalMeshComponent** MeshComp (BlueprintVisible, BlueprintReadOnly, Parm, ZeroConstructor, InstancedReference, IsPlainOldData)
// class UAnimSequenceBase** Animation (BlueprintVisible, BlueprintReadOnly, Parm, ZeroConstructor, IsPlainOldData)
// bool ReturnValue (Parm, OutParm, ZeroConstructor, ReturnParm, IsPlainOldData)
bool UBP_AnimNotify_RequestAnimation_C::Received_Notify(class USkeletalMeshComponent** MeshComp, class UAnimSequenceBase** Animation)
{
static auto fn = UObject::FindObject<UFunction>("Function BP_AnimNotify_RequestAnimation.BP_AnimNotify_RequestAnimation_C.Received_Notify");
UBP_AnimNotify_RequestAnimation_C_Received_Notify_Params params;
params.MeshComp = MeshComp;
params.Animation = Animation;
auto flags = fn->FunctionFlags;
UObject::ProcessEvent(fn, ¶ms);
fn->FunctionFlags = flags;
return params.ReturnValue;
}
}
#ifdef _MSC_VER
#pragma pack(pop)
#endif
| [
"35783139+LemonHaze420@users.noreply.github.com"
] | 35783139+LemonHaze420@users.noreply.github.com |
27b7feb22e4bd34a5da40208eb5fe03a13dd3799 | 49eb0d08311529b1d2375429a9cbb5582d77fd2d | /src/wallet/coincontrol.h | 13c19452fdedec67c923708586a9042d42233581 | [
"MIT"
] | permissive | mario1987/deimos | bcbaa7b4ed617a70c37047e6590264941b94a170 | 72cb8c33b5a6d4e09e4019602db7cea8c686d505 | refs/heads/master | 2020-03-19T23:11:08.313125 | 2018-06-11T23:06:30 | 2018-06-11T23:06:30 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,938 | h | // Copyright (c) 2011-2016 The DeiMos Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#ifndef DEIMOS_WALLET_COINCONTROL_H
#define DEIMOS_WALLET_COINCONTROL_H
#include "primitives/transaction.h"
/** Coin Control Features. */
class CCoinControl
{
public:
CTxDestination destChange;
//! If false, allows unselected inputs, but requires all selected inputs be used
bool fAllowOtherInputs;
//! Includes watch only addresses which match the ISMINE_WATCH_SOLVABLE criteria
bool fAllowWatchOnly;
//! Minimum absolute fee (not per kilobyte)
CAmount nMinimumTotalFee;
//! Override estimated feerate
bool fOverrideFeeRate;
//! Feerate to use if overrideFeeRate is true
CFeeRate nFeeRate;
//! Override the default confirmation target, 0 = use default
int nConfirmTarget;
CCoinControl()
{
SetNull();
}
void SetNull()
{
destChange = CNoDestination();
fAllowOtherInputs = false;
fAllowWatchOnly = false;
setSelected.clear();
nMinimumTotalFee = 0;
nFeeRate = CFeeRate(0);
fOverrideFeeRate = false;
nConfirmTarget = 0;
}
bool HasSelected() const
{
return (setSelected.size() > 0);
}
bool IsSelected(const COutPoint& output) const
{
return (setSelected.count(output) > 0);
}
void Select(const COutPoint& output)
{
setSelected.insert(output);
}
void UnSelect(const COutPoint& output)
{
setSelected.erase(output);
}
void UnSelectAll()
{
setSelected.clear();
}
void ListSelected(std::vector<COutPoint>& vOutpoints) const
{
vOutpoints.assign(setSelected.begin(), setSelected.end());
}
private:
std::set<COutPoint> setSelected;
};
#endif // DEIMOS_WALLET_COINCONTROL_H
| [
"support@lipcoins.org"
] | support@lipcoins.org |
aecce31bc677d44685e9120a39e39d331eed049d | 01e1ab7e8ae116b42d993352371e94db9e4efe75 | /chapter1/BasicArithmeticGenerator/BasicArithmeticGenerator/arithmetic_expression.cpp | 9910556c39a344991b6ed2fe624502f1c32042a3 | [] | no_license | mmz-zmm/BuildToWin | 1ac07d2ca88ff395fd808f1c59167b40a13f8e33 | 201d6605f06ad336cfa30b75807627cf755b521b | refs/heads/master | 2021-09-10T07:52:21.339877 | 2018-03-22T12:00:35 | 2018-03-22T12:00:35 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 10,035 | cpp | #include "stdafx.h"
#include "arithmetic_expression.h"
#include <random>
#include <iostream>
#include <sstream>
#include <ctime>
#include <cctype>
static wstring operators = L"-+x÷^";
void swap_subtree(tree_node * &mid, tree_node *&left, tree_node * &right)
{
tree_node * tmp = left;
mid->left = right;
mid->right = tmp;
}
bool subtree_lesser(const tree_node * tree1, const tree_node * tree2)
{
return (tree1->value < tree2->value) ? true : false;
}
void update_infix_expression(tree_node * current)
{
tree_node * left = current->left;
tree_node * right = current->right;
wchar_t op = current->op;
wchar_t left_op = left->op;
wchar_t right_op = right->op;
bool left_brace{ false };
bool right_brace{ false };
// 判断左表达式否需要加括号
if ((op == L'x' || op == L'÷') && (left_op == L'+' || left_op == L'-'))
{
left_brace = true;
}
// 判断右表达式否需要加括号
if (right->op != L'0')
{
switch (op)
{
case L'+':
right_brace = (right->op == L'-');
break;
case L'-':
right_brace = (right->op == L'+' || right->op == L'-');
break;
case L'x':
right_brace = (right->op == L'+' || right->op == L'-' || right->op == L'÷');
break;
case L'÷':
right_brace = (right->op == L'+' || right->op == L'-' || right->op == L'x' || right->op == L'÷');
break;
case L'^':
right_brace = true;
break;
}
}
current->exp = (left_brace ? L"( " + left->exp + L" )" : left->exp) +
L" " + wstring(&op, &op + 1) + L" " +
(right_brace ? L"( " + right->exp + L" )" : right->exp);
}
wstring postfix_to_infix(tree_node * root)
{
if (root != nullptr)
{
stack<tree_node*> stack_tree;
tree_node* current = root;
tree_node* previous = nullptr;
while (current != nullptr || !stack_tree.empty())
{
while (current != nullptr)
{
stack_tree.push(current);
current = current->left;
}
current = stack_tree.top();
if (current->right == nullptr || current->right == previous)
{
if (current->op != L'0')
update_infix_expression(current);
stack_tree.pop();
previous = current;
current = nullptr;
}
else
{
current = current->right;
}
}
return root->exp;
}
else
return L"";
}
void arithmetic_expression::add_operator_node_to_tree(stack<tree_node*> &tree, wchar_t op)
{
tree_node * right = tree.top(); tree.pop();
tree_node * left = tree.top(); tree.pop();
if (op == L'÷' && right->value.numerator == 0)
{
unsigned new_op_id;
while (op == L'÷') //产生非÷新符号
{
new_op_id = generate_operator();
op = operators[new_op_id];
}
}
MyFraction f = select_operation(left->value, right->value, op);
tree_node * mid = new tree_node(f, op, left, right);
if ((op == L'+' || op == L'x') && subtree_lesser(right, left))
{
swap_subtree(mid, left, right);
}
if (op == L'-' && f.numerator < 0)
{
swap_subtree(mid, left, right);
(mid->value).numerator = -f.numerator;
}
tree.push(mid);
}
arithmetic_expression& arithmetic_expression::generate_expression()
{
stack<tree_node*> tree;
unsigned item_count{ 0 };
unsigned op_count{ 0 };
while (op_count < operator_number)
{
if (item_count < 2 || item_count - 1 <= op_count )
{
MyFraction number = generate_random_number();
tree_node* node = new tree_node(number);
tree.push(node);
item_count++;
}
else if (item_count <= operator_number)
{
pair<MyFraction, bool> next = generate_random_number_or_operator();
if (next.second)
{
tree_node* node = new tree_node(next.first);
tree.push(node);
item_count++;
}
else
{
unsigned op_id = (next.first).numerator;
wchar_t op = operators[op_id];
add_operator_node_to_tree(tree, op);
op_count++;
}
}
else
{
unsigned op_id = generate_operator();
wchar_t op = operators[op_id];
add_operator_node_to_tree(tree, op);
op_count++;
}
}
root = tree.top();
postfix_to_infix(root);
return *this;
}
MyFraction arithmetic_expression::generate_random_number()
{
static default_random_engine e((unsigned)time(nullptr));
static uniform_int_distribution<unsigned> natural_fraction(0, 1);
static uniform_int_distribution<unsigned> natural(1, number_range - 1);
MyFraction result;
unsigned choice = natural_fraction(e);
if (choice == 0)
{
result = MyFraction(natural(e), 1).reduction();
}
else if (choice == 1)
{
unsigned a = natural(e);
unsigned b = natural(e);
result = MyFraction(a, b).reduction();
}
return result;
}
unsigned arithmetic_expression::generate_operator()
{
static default_random_engine e((unsigned)time(nullptr));
static uniform_int_distribution<unsigned> random_operator(0, 3);
return random_operator(e);
}
wstring infix_to_postfix_expression( const wstring& infix)
{
wistringstream input(infix);
stack<int> Stack;
wstring postfix_expression;
for (wstring token; getline(input, token, L' ');)
{
wchar_t c = token.at(0);
auto pos1 = operators.find(c);
if (pos1 != wstring::npos)
{
if (Stack.empty())
Stack.push(pos1);
else
{
while (!Stack.empty())
{
int priority1 = pos1 / 2;
int priority2 = Stack.top() / 2;
if (priority2 > priority1 || (priority2 == priority1 && c != L'^'))
{
int pos2 = Stack.top();
Stack.pop();
postfix_expression.append(wstring(1, operators[pos2]).append(L" "));
}
else
break;
}
Stack.push(pos1);
}
}
else if (c == L'(')
{
Stack.push(-2); // -2 stands for 'C'
}
else if (c == L')')
{
while (!Stack.empty() && Stack.top() != -2)
{
int pos2 = Stack.top();
Stack.pop();
postfix_expression.append(wstring(1, operators[pos2]).append(L" "));
}
Stack.pop();
}
else
{
postfix_expression.append(token).append(L" ");
}
}
while (!Stack.empty())
{
int pos2 = Stack.top();
Stack.pop();
postfix_expression.append(wstring(1, operators[pos2]).append(L" "));
}
return postfix_expression;
}
pair<MyFraction, bool> arithmetic_expression::generate_random_number_or_operator()
{
static default_random_engine e((unsigned)time(nullptr));
static uniform_int_distribution<unsigned> number_or_operator(0, 1);
unsigned r = number_or_operator(e);
if (r == 1)
{
unsigned op = generate_operator();
return { MyFraction(op, 1), false };
}
else
{
MyFraction number = generate_random_number();
return{ number, true };
}
}
MyFraction infix_expression_solve(const wstring & infix)
{
wstring postfix = infix_to_postfix_expression(infix);
return postfix_expression_solve(postfix);
}
struct expression_with_op
{
wstring expression;
wchar_t op;
};
wstring postfix_to_infix_expression(const wstring & post)
{
wistringstream input(post);
stack<expression_with_op> expressions;
for (wstring token; getline(input, token, L' ');)
{
wchar_t c = token.at(0);
if (L'0' <= c && c <= L'9')
{
struct expression_with_op item ={ token, c };
expressions.push(item);
}
else
{
auto right = expressions.top(); expressions.pop();
auto left = expressions.top(); expressions.pop();
bool left_brace = false;
bool right_brace = false;
// 判断左表达式否需要加括号
if ((c == L'x' || c == L'÷') && (left.op == L'+' || left.op == L'-'))
{
left_brace = true;
}
if ((left.op < L'0' || L'9' < left.op) && c == L'^')
{
left_brace = true;
}
// 判断右表达式否需要加括号
if (right.op < L'0' || L'9' < right.op)
{
switch (c)
{
case L'+':
right_brace = (right.op == L'-');
break;
case L'-':
right_brace = (right.op == L'+' || right.op == L'-');
break;
case L'x':
right_brace = (right.op == L'+' || right.op == L'-' || right.op == L'÷');
break;
case L'÷':
right_brace = (right.op == L'+' || right.op == L'-' || right.op ==L'x' || right.op == L'÷');
break;
case L'^':
right_brace = true;
break;
}
}
wstring new_expression =
(left_brace ? L"(" + left.expression + L")" : left.expression) +
L" " + wstring(&c, &c + 1) + L" " +
(right_brace ? L"(" + right.expression + L")" : right.expression);
expressions.push({ new_expression, c });
}
}
return expressions.top().expression;
}
MyFraction postfix_expression_solve(const wstring & postfix)
{
wistringstream input(postfix);
stack<MyFraction> Stack;
for (wstring token; getline(input, token, L' ');)
{
wchar_t c = token.at(0);
auto pos1 = operators.find(c);
if (pos1 == wstring::npos)
{
size_t slash_index = token.find(L'/');
int a = stoi(token.substr(0, slash_index));
int b = stoi(token.substr(slash_index + 1));
Stack.push(MyFraction(a, b));
}
else
{
MyFraction f2 = Stack.top(); Stack.pop();
MyFraction f1 = Stack.top(); Stack.pop();
MyFraction f3 = select_operation(f1, f2, c);
Stack.push(f3);
}
}
MyFraction result = Stack.top();
return result.reduction();
}
MyFraction select_operation(const MyFraction & f1, const MyFraction & f2, wchar_t op)
{
MyFraction result;
switch (op)
{
case L'+': result = f1 + f2; break;
case L'-': result = f1 - f2; break;
case L'x': result = f1 * f2; break;
case L'÷': result = f1 / f2; break;
}
return result;
}
wstring format_output(const wstring & expression)
{
wistringstream input(expression);
wstring result;
for (wstring token; getline(input, token, L' ');)
{
wchar_t c = token.at(0);
if (L'0' <= c && c <= L'9')
{
size_t slash_index = token.find(L'/');
int a = stoi(token.substr(0, slash_index));
int b = stoi(token.substr(slash_index + 1));
result.append(MyFraction(a, b).format_output());
result.append(L" ");
}
else
{
result.append(token);
result.append(L" ");
}
}
return result;
}
arithmetic_expression::~arithmetic_expression()
{
tree_destroy(root);
}
void arithmetic_expression::tree_destroy(tree_node *root)
{
tree_node * current = root;
if (current != nullptr)
{
tree_destroy(current->left);
tree_destroy(current->right);
delete current;
}
current = nullptr;
}
| [
"zhaomzhao@hotmail.com"
] | zhaomzhao@hotmail.com |
4ad2ae8c75c8e8ebd78377297390ac770dbe00f2 | 3d1900860202c28b11cd44ba088f5eb8a29f86cc | /Plugins/DialoguePlugin_4_25/Source/DialoguePlugin/Private/DialogueUserWidget.cpp | 3cb45815571851171d9bd0ee601a47b92b6f55b4 | [] | no_license | Aieko/TDGame | 221a7c6488fb3c823bb8edb3dd59625319bea064 | 3cecd93a89dfa94ed6005868834b1aa215967aaf | refs/heads/master | 2023-03-14T16:57:56.327935 | 2021-03-19T23:23:51 | 2021-03-19T23:23:51 | 331,007,513 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,915 | cpp | // Copyright Underflow Studios 2017
#include "DialogueUserWidget.h"
#include "UObject/UnrealType.h"
#include "UObject/Class.h"
#include "Dialogue.h"
bool UDialogueUserWidget::IsConditionsMetForNode_Implementation(FDialogueNode Node)
{
for (UDialogueConditions* Condition : Node.Conditions)
{
if (IsValid(Condition))
{
if (!Condition->IsConditionMet(GetOwningPlayer(), NPCActor))
{
return false;
}
}
}
return true;
}
void UDialogueUserWidget::RunEventsForNode_Implementation(FDialogueNode Node)
{
for (UDialogueEvents* Event : Node.Events)
{
if (IsValid(Event))
{
Event->RecieveEventTriggered(GetOwningPlayer(), NPCActor);
}
}
}
/* If you supply this function with "charname", it'll run the function called Get_charname
* It'll also make sure that your Get_charname function has no parameters and only returns a string
* The resulting string will be returned in &resultString
*/
bool UDialogueUserWidget::RunStringReplacer(FString originalString, FString& resultString)
{
const FString methodToCall = FString::Printf(TEXT("Get_%s"), *originalString);
UFunction* Func = GetClass()->FindFunctionByName(FName(*methodToCall), EIncludeSuperFlag::ExcludeSuper);
if (Func == nullptr)
{
UE_LOG(LogTemp, Error, TEXT("Dialogue Plugin: Function \"%s\" wasn't found on the dialogue widget."), *methodToCall);
return false;
}
int foundReturnStrings = 0;
for (TFieldIterator<FProperty> It(Func); It; ++It)
{
FProperty* Prop = *It;
// print property flags
//uint64 flags = (uint64)Prop->GetPropertyFlags();
//UE_LOG(LogTemp, Log, TEXT("Property Flags: %llu"), flags); // convert to hex: https://www.rapidtables.com/convert/number/decimal-to-hex.html
// if it's a return type (in blueprints it's an out parameter), check that it's a string
if (Prop->HasAllPropertyFlags(CPF_Parm | CPF_OutParm))
{
if (!Prop->GetCPPType().Equals(TEXT("FString")))
{
// if we land here, it means our method returns something other than a string
UE_LOG(LogTemp, Error, TEXT("Dialogue Plugin: Your method \"%s\" is returning something other than a string!"), *methodToCall);
return false;
}
else
{
foundReturnStrings++;
}
}
// if it's a normal parameter, return false
else if (Prop->HasAnyPropertyFlags(CPF_Parm) && !Prop->HasAnyPropertyFlags(CPF_OutParm))
{
// we have some parameters, but we shouldn't have them
UE_LOG(LogTemp, Error, TEXT("Dialogue Plugin: Your method \"%s\" must have no parameters!"), *methodToCall);
return false;
}
}
if (foundReturnStrings > 1)
{
UE_LOG(LogTemp, Error, TEXT("Dialogue Plugin: Your method \"%s\" must return only one string!"), *methodToCall);
return false;
}
else if (foundReturnStrings == 0)
{
UE_LOG(LogTemp, Error, TEXT("Dialogue Plugin: Your method \"%s\" doesn't return anything, but must return a string!"), *methodToCall);
return false;
}
FString retvalue;
ProcessEvent(Func, &retvalue);
resultString = retvalue;
return true;
}
/* In the supplied inText, finds all strings of that fit the pattern %string% (a single word between two percentage signs)
* and returns an array of them without the percentage sign.
*/
TArray<FString> UDialogueUserWidget::FindVarStrings(FText inText)
{
TArray<FString> varStrings;
FString totalText = inText.ToString();
int firstPercent = -1;
for (int i = 0; i < totalText.Len(); i++)
{
if (totalText[i] == '%')
{
if (firstPercent == -1) // if we encounter the first % sign
{
firstPercent = i;
}
else if (firstPercent + 1 == i) //if we encounter "%%", disregard the first one
{
firstPercent = i;
}
else // if we encounter second % sign
{
FString foundVarString = totalText.Mid(firstPercent + 1, i - firstPercent - 1);
varStrings.AddUnique(foundVarString);
firstPercent = -1;
}
}
if (totalText[i] == ' ')
{
firstPercent = -1;
}
}
return varStrings;
} | [
"Aieko666@hotmail.com"
] | Aieko666@hotmail.com |
2bdac7b311a0606f9c9a7911ce75be2ce8270897 | 7fb22ada43c55707bbbab6f7a0f5728d5d0a6c1a | /src/flux_tools/FluxFitter.cxx | 04edd60fe9030db91dbd2cbf5c809f6f0c2f0285 | [
"MIT"
] | permissive | cvilelahep/DUNEPrismTools | 15c817d686ce823cd0a4683cdc668ec7a7eaf5f4 | b84c0ff620839d463c219f84cc6a884be486f484 | refs/heads/master | 2021-10-02T20:48:52.303880 | 2018-11-19T20:34:57 | 2018-11-19T20:34:57 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 10,323 | cxx | #include "FluxFitter.hxx"
#include "SliceConfigTreeReader.hxx"
#include "ROOTUtility.hxx"
#include "StringParserUtility.hxx"
#include "Fit/Fitter.h"
#include "Math/Factory.h"
#include "Math/Functor.h"
#include <algorithm>
#include <chrono>
#include <functional>
// #define DEBUG_LHOOD
void FluxFitter::Initialize(FluxFitterOptions const &ffo) {
fFitterOpts = ffo;
std::cout << "[INFO]: Initializing fit with: " << DumpFluxFitterOptions(ffo)
<< std::endl;
}
void FluxFitter::InitializeFlux(
FluxFitter::FluxFitterOptions const &ffo,
FluxTargetLikelihood::FluxTargetOptions const &fto,
bool ExpectTargetLater) {
Initialize(ffo);
std::cout << "[INFO]: Initializing Flux fit with: "
<< DumpFluxTargetOptions(fto) << std::endl;
fFitterOpts.IsGauss = false;
std::unique_ptr<FluxTargetLikelihood> fluxLHood =
std::make_unique<FluxTargetLikelihood>();
fluxLHood->Initialize(fto);
LHoodEval = std::move(fluxLHood);
if (!ExpectTargetLater) {
if (!fFitterOpts.InputTargetFluxFile.size() ||
!fFitterOpts.InputTargetFluxName.size()) {
std::cout << "[ERROR]: No target flux file specified." << std::endl;
throw;
}
tgtFlux = GetHistogram_uptr<TH1D>(fFitterOpts.InputTargetFluxFile,
fFitterOpts.InputTargetFluxName);
SetTargetFlux(tgtFlux.get(), true);
}
}
void FluxFitter::InitializeGauss(
FluxFitter::FluxFitterOptions const &ffo,
GausTargetLikelihood::GausTargetOptions const >o) {
Initialize(ffo);
std::cout << "[INFO]: Initializing Gaus fit with: "
<< DumpGausTargetOptions(gto) << std::endl;
fFitterOpts.IsGauss = true;
std::unique_ptr<GausTargetLikelihood> gausLHood =
std::make_unique<GausTargetLikelihood>();
gausLHood->Initialize(gto);
LHoodEval = std::move(gausLHood);
InitializeCoefficientGuess();
}
void FluxFitter::InitializeCoefficientGuess() {
Coefficients.clear();
size_t NFluxes = LHoodEval->GetNFluxes();
std::fill_n(std::back_inserter(Coefficients), NFluxes, 0);
if (fFitterOpts.InpCoeffFile.size()) {
if (fFitterOpts.InpCoeffDir.size() &&
(fFitterOpts.InpCoeffDir.back() != '/')) {
fFitterOpts.InpCoeffDir += "/";
}
std::cout << "[INFO]: Reading input previous fit results." << std::endl;
SliceConfig sc(fFitterOpts.InpCoeffFile, fFitterOpts.InpCoeffDir);
std::vector<std::pair<double, double>> inpXRanges = sc.GetXRanges();
std::vector<double> inpCoeffs = sc.GetCoeffs();
if (inpXRanges.size() != LHoodEval->fFSO.XRanges.size()) {
std::cout << "[ERROR]: Input fit result had " << inpXRanges.size()
<< " off-axis slices, but here we have found "
<< LHoodEval->fFSO.XRanges.size()
<< ". Input results are incompatible." << std::endl;
throw;
}
for (size_t f_it = 0; f_it < inpXRanges.size(); ++f_it) {
if ((fabs(inpXRanges[f_it].first -
(100. * LHoodEval->fFSO.XRanges[f_it].first)) > 1E-5) ||
(fabs(inpXRanges[f_it].second -
(100. * LHoodEval->fFSO.XRanges[f_it].second)) > 1E-5)) {
std::cout << "\tFlux window[" << f_it << "] = {"
<< inpXRanges[f_it].first << " -- " << inpXRanges[f_it].second
<< "}, Coeff = " << inpCoeffs[f_it] << std::endl;
std::cout << "[ERROR]: Here we found Flux window[" << f_it << "] = {"
<< LHoodEval->fFSO.XRanges[f_it].first << " -- "
<< LHoodEval->fFSO.XRanges[f_it].second
<< "}. Input results are incompatible." << std::endl;
throw;
}
Coefficients[f_it] = inpCoeffs[f_it];
}
} else {
size_t flux_with_closest_peak_it = LHoodEval->GetNearestPeakingFluxIndex();
for (size_t flux_it = 0; flux_it < NFluxes; flux_it++) {
if (abs(flux_it - flux_with_closest_peak_it) ==
1) { // Neighbours are negative
Coefficients[flux_it] = -0.35;
} else if (abs(flux_it - flux_with_closest_peak_it) == 0) {
Coefficients[flux_it] = 1;
} else { // Others start free
Coefficients[flux_it] = 0;
}
}
}
}
bool FluxFitter::Fit() {
size_t NFluxes = LHoodEval->GetNFluxes();
if (!fMinimizer) {
fMinimizer = std::unique_ptr<ROOT::Math::Minimizer>(
ROOT::Math::Factory::CreateMinimizer("Minuit2", "Migrad"));
}
fMinimizer->SetMaxFunctionCalls(fFitterOpts.MaxLikelihoodCalls);
fMinimizer->SetTolerance(fFitterOpts.MINUITTolerance);
for (size_t flux_it = 0; flux_it < NFluxes; flux_it++) {
std::stringstream ss("");
ss << "fluxpar" << flux_it;
fMinimizer->SetVariable(flux_it, ss.str().c_str(), Coefficients[flux_it],
0.1);
fMinimizer->SetVariableLimits(flux_it, -fFitterOpts.CoeffLimit,
fFitterOpts.CoeffLimit);
}
auto lap = std::chrono::high_resolution_clock::now();
ROOT::Math::Functor fcn(
[&](double const *coeffs) {
if (LHoodEval->GetNLHCalls() && !(LHoodEval->GetNLHCalls() % 5000)) {
auto diff = std::chrono::duration_cast<std::chrono::seconds>(
std::chrono::high_resolution_clock::now() - lap);
lap = std::chrono::high_resolution_clock::now();
std::cout << "[INFO]: Call: " << LHoodEval->GetNLHCalls()
<< ", Last 5k calls took " << diff.count() << "s"
<< std::endl;
std::cout << "[INFO]: Likelihood state: " << LHoodEval->State()
<< std::endl;
}
#ifdef DEBUG_LHOOD
std::cout << "[INFO]: Step " << fcn_call << std::endl;
for (size_t c = 0; c < NFluxes; ++c) {
std::cout << "\t c[" << c << "] = " << coeffs[c] << std::endl;
}
#endif
double lh = LHoodEval->GetLikelihood(coeffs);
#ifdef DEBUG_LHOOD
std::cout << "LH = " << lh << std::endl;
#endif
return lh;
},
NFluxes);
fMinimizer->SetFunction(fcn);
fMinimizer->Minimize();
int fitstatus = fMinimizer->Status();
if (fitstatus) {
std::cout << "[WARN]: Failed to find minimum (STATUS: " << fitstatus << ")."
<< std::endl;
}
for (size_t flux_it = 0; flux_it < NFluxes; flux_it++) {
Coefficients[flux_it] = fMinimizer->X()[flux_it];
}
return (!fitstatus);
}
void FluxFitter::SetCoefficients(std::vector<double> coeffs_new) {
Coefficients = std::move(coeffs_new);
}
void FluxFitter::SetTargetFlux(TH1D const *tgt, bool GuessCoefficients) {
if (fFitterOpts.IsGauss) {
std::cout << "[ERROR]: Attempted to SetTargetFlux on a FluxFitter that is "
"configured to fit gaussian fluxes."
<< std::endl;
throw;
}
dynamic_cast<FluxTargetLikelihood *>(LHoodEval.get())->SetTargetFlux(tgt);
if (GuessCoefficients) {
InitializeCoefficientGuess();
}
}
void FluxFitter::SetGaussParameters(double GaussC, double GaussW,
bool GuessCoefficients) {
if (!fFitterOpts.IsGauss) {
std::cout << "[ERROR]: Attempted to SetGaussParameters on a FluxFitter "
"that is configured to fit target fluxes."
<< std::endl;
throw;
}
dynamic_cast<GausTargetLikelihood *>(LHoodEval.get())
->SetGaussParameters(GaussC, GaussW);
if (GuessCoefficients) {
InitializeCoefficientGuess();
}
}
void FluxFitter::Write(TDirectory *td) {
LHoodEval->Write(td, Coefficients.data());
}
#ifdef USE_FHICL
FluxFitter::FluxFitterOptions
MakeFluxFitterOptions(fhicl::ParameterSet const &ps) {
FluxFitter::FluxFitterOptions ffo;
ffo.InpCoeffFile = ps.get<std::string>("InputCoefficientsFile", "");
ffo.InpCoeffDir = ps.get<std::string>("InputCoefficientsDirectory", "");
ffo.InputTargetFluxFile = ps.get<std::string>("InputTargetFluxFile", "");
ffo.InputTargetFluxName = ps.get<std::string>("InputTargetFluxName", "");
ffo.CoeffLimit = ps.get<double>("CoeffLimit", 10);
ffo.MaxLikelihoodCalls = ps.get<size_t>("MaxLikelihoodCalls", 5E5);
ffo.MINUITTolerance = ps.get<double>("MINUITTolerance", 1E-5);
return ffo;
}
#endif
FluxFitter::FluxFitterOptions MakeFluxFitterOptions(int argc,
char const *argv[]) {
FluxFitter::FluxFitterOptions ffo;
ffo.IsGauss = false;
ffo.InpCoeffFile = "";
ffo.InpCoeffDir = "";
ffo.InputTargetFluxFile = "";
ffo.InputTargetFluxName = "";
ffo.CoeffLimit = 10;
ffo.MaxLikelihoodCalls = 5E5;
ffo.MINUITTolerance = 1E-5;
int opt = 1;
while (opt < argc) {
if (std::string(argv[opt]) == "-A") {
std::vector<std::string> params =
ParseToVect<std::string>(argv[++opt], ",");
ffo.InpCoeffFile = params[0];
if (params.size() > 1) {
ffo.InpCoeffDir = params[1];
} else {
ffo.InpCoeffDir = "";
}
} else if (std::string(argv[opt]) == "-t") {
std::vector<std::string> params =
ParseToVect<std::string>(argv[++opt], ",");
if (params.size() != 2) {
std::cout << "[ERROR]: Recieved " << params.size()
<< " entrys for -t, expected 2." << std::endl;
throw;
}
ffo.InputTargetFluxFile = params[0];
ffo.InputTargetFluxName = params[1];
} else if (std::string(argv[opt]) == "-n") {
ffo.MaxLikelihoodCalls = str2T<int>(argv[++opt]);
} else if (std::string(argv[opt]) == "-T") {
ffo.MINUITTolerance = str2T<double>(argv[++opt]);
} else if (std::string(argv[opt]) == "-c") {
ffo.CoeffLimit = str2T<double>(argv[++opt]);
}
opt++;
}
return ffo;
}
std::string DumpFluxFitterOptions(FluxFitter::FluxFitterOptions const &ffo) {
std::stringstream ss("");
std::cout << "{" << std::endl;
ss << "\tIsGauss: " << ffo.IsGauss << std::endl;
ss << "\tInpCoeffFile: " << ffo.InpCoeffFile << std::endl;
ss << "\tInpCoeffDir: " << ffo.InpCoeffDir << std::endl;
ss << "\tInputTargetFluxFile: " << ffo.InputTargetFluxFile << std::endl;
ss << "\tInputTargetFluxName: " << ffo.InputTargetFluxName << std::endl;
ss << "\tCoeffLimit: " << ffo.CoeffLimit << std::endl;
ss << "\tMaxLikelihoodCalls: " << ffo.MaxLikelihoodCalls << std::endl;
ss << "\tMINUITTolerance: " << ffo.MINUITTolerance << std::endl;
ss << "}" << std::endl;
return ss.str();
}
| [
"luketpickering@googlemail.com"
] | luketpickering@googlemail.com |
9cdfdae32d7c183aaa8771699429622bb5d4f587 | b8eb357354eeef47b1675031a0b350dd297a81ef | /54. Spiral Matrix - Medium - Pass/cpp.cpp | 3b69b463b04ad99203912764108f5b9155e32b1b | [] | no_license | wsyzxxxx/LeetcodeGOGOGO | 3e9dd70f01db220048683688f71e7b88d3921d08 | 48418ce917baf05390f1bc8df35aba9e0516f97b | refs/heads/master | 2021-11-26T17:29:23.065653 | 2021-10-29T18:23:32 | 2021-10-29T18:23:32 | 195,494,436 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,173 | cpp | class Solution {
public:
vector<int> spiralOrder(vector<vector<int>>& matrix) {
if (matrix.empty() || matrix[0].empty()) {
return {};
}
int up = 0;
int low = matrix.size();
int left = 0;
int right = matrix[0].size();
std::vector<int> res;
while (up < low || left < right) {
if (up < low) {
for (int i = left; i < right; i++) {
res.push_back(matrix[up][i]);
}
up++;
}
if (left < right) {
for (int i = up; i < low; i++) {
res.push_back(matrix[i][right-1]);
}
right--;
}
if (up < low) {
for (int i = right-1; i >= left; i--) {
res.push_back(matrix[low-1][i]);
}
low--;
}
if (left < right) {
for (int i = low-1; i >= up; i--) {
res.push_back(matrix[i][left]);
}
left++;
}
}
return res;
}
};
| [
"645658325@qq.com"
] | 645658325@qq.com |
6e097dded0b3c555fd85a73a34a73d91b519b0c1 | c8963464141bf77e314ccded867df0facbe45ffa | /algorithm/treeBurrowsWheelerTransform/builder.cpp | ae4f033ff7e15d55118f9460fee3cbbdd7f96ae2 | [] | no_license | cle-ment/path-index-graph-kernel | 01616b80b11fa466609158f2d5f0da872ebd5cfd | 485167d65f519bb3eb310fb0fe9fc33aefb69c0c | refs/heads/master | 2018-09-06T21:32:41.909338 | 2014-04-10T16:02:36 | 2014-04-10T16:02:36 | 13,365,718 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 10,423 | cpp |
#include "SimpleForest.h"
#include "TBWTBuilder.h"
#include "BitRank.h"
#include "HuffWT.h"
#include <sstream>
#include <iostream>
#include <stdexcept>
#include <fstream>
#include <string>
#include <ctime>
#include <cstring>
#include <cassert>
#include <getopt.h>
using namespace std;
/**
* Definitions for parsing command line options
*/
enum parameter_t { long_opt_rlcsa = 256, long_opt_debug };
/**
* Flags set based on command line parameters
*/
bool verbose = false;
bool debug = false;
int atoi_min(char const *value, int min, char const *parameter, char const *name)
{
std::istringstream iss(value);
int i;
char c;
if (!(iss >> i) || iss.get(c))
{
cerr << "builder: argument of " << parameter << " must be of type <int>, and greater than or equal to " << min << endl
<< "Check README or `" << name << " --help' for more information." << endl;
std::exit(1);
}
if (i < min)
{
cerr << "builder: argument of " << parameter << " must be greater than or equal to " << min << endl
<< "Check README or `" << name << " --help' for more information." << endl;
std::exit(1);
}
return i;
}
void input_size(istream *input, unsigned &entries, ulong &trees, ulong &nodes)
{
entries = 0;
trees = 0;
nodes = 0;
string row;
while (getline(*input, row).good())
{
if (row[0] == '>')
++entries;
else
{
++trees;
if (row.size() % 3 != 0)
{
cerr << "error: invalid input row length at row:" << endl
<< row << endl;
abort();
}
nodes += row.size()/3;
}
}
}
void parse_entries(istream *input, SimpleForest *nf, ulong *entry, ulong estimatedLength, time_t wctime)
{
unsigned entries = 0;
unsigned node = 0;
ulong j = 0;
string row;
string name = "undef";
while (getline(*input, row).good())
{
j += row.size();
if (row[0] == '>')
{
// Mark first tree in this entry
Tools::SetField(entry, 1, node, 1);
name = row.substr(1);
++entries;
if (verbose && entries % 100 == 0 )
{
cerr << "Inserting entry n:o " << entries << ", name: " << name << " (";
if (estimatedLength)
cerr << (100*j/estimatedLength) << "%, ";
cerr << "elapsed " << std::difftime(time(NULL), wctime) << " s, "
<< std::difftime(time(NULL), wctime) / 3600 << " hours)" << endl;
}
}
else
{
node += row.size() / 3;
nf->add(row);
}
}
row.clear();
}
void print_usage(char const *name)
{
cerr << "usage: " << name << " [options] <input> [output]" << endl
<< "Check README or `" << name << " --help' for more information." << endl;
}
void print_help(char const *name)
{
cerr << "usage: " << name << " [options] <input> [output]" << endl << endl
<< "<input> is the input filename. "
<< "The input must be in FASTA format." << endl
<< "If no output filename is given, the index is stored as <input>.fmi" << endl
<< "or as <input>.rlcsa." << endl << endl
<< "Options:" << endl
<< " -h, --help Display command line options." << endl
<< " -v, --verbose Print progress information." << endl;
}
int main(int argc, char **argv)
{
/**
* Parse command line parameters
*/
if (argc == 1)
{
print_usage(argv[0]);
return 1;
}
static struct option long_options[] =
{
{"help", no_argument, 0, 'h'},
{"verbose", no_argument, 0, 'v'},
{"debug", no_argument, 0, long_opt_debug},
{0, 0, 0, 0}
};
int option_index = 0;
int c;
while ((c = getopt_long(argc, argv, "hv",
long_options, &option_index)) != -1)
{
switch(c)
{
case 'h':
print_help(argv[0]);
return 0;
case 'v':
verbose = true; break;
case long_opt_debug:
debug = true; break;
case '?':
print_usage(argv[0]);
return 1;
default:
print_usage(argv[0]);
std::abort();
}
}
if (argc - optind < 1)
{
cerr << "builder: no input filename given!" << endl;
print_usage(argv[0]);
return 1;
}
if (argc - optind > 2)
cerr << "Warning: too many filenames given! Ignoring all but first two." << endl;
string inputfile = string(argv[optind++]);
string outputfile = inputfile;
if (optind != argc)
outputfile = string(argv[optind++]);
outputfile += ".tbwt";
istream *fp;
/*if (inputfile == "-")
fp = &std::cin; // Not supported here!
else*/
fp = new std::ifstream(inputfile.c_str());
if (!fp->good())
{
cerr << "builder: unable to read input file " << inputfile << endl;
exit(1);
}
cerr << std::fixed;
cerr.precision(2);
time_t wctime = time(NULL);
// estimate the total input sequence length
fp->seekg(0, ios::end);
long estLength = fp->tellg();
if (estLength == -1)
{
cerr << "error: unable to seek input file" << endl;
estLength = 0;
}
fp->seekg(0);
if (verbose)
cerr << "Input file size is " << estLength/1024 << " kb." << endl;
/**
* Count the input sizes
*/
unsigned entries = 0;
ulong trees = 0, nodes = 0;
input_size(fp, entries, trees, nodes);
fp->clear(); // forget previous EOF
fp->seekg(0);
if (verbose)
cerr << "Number of FASTA entries: " << entries << endl
<< "Total number of trees: " << trees << endl
<< "Total number of nodes: " << nodes << endl
<< "Parsing the input..." << endl;
/**
* Parse all trees
*/
// Bitvector that marks the first root node in each entry
ulong *entry = new ulong[nodes/W + 1];
for (unsigned i = 0; i < nodes/W + 1; ++i)
entry[i] = 0;
SimpleForest *nf = new SimpleForest(entries, trees, nodes);
parse_entries(fp, nf, entry, estLength, wctime);
if (debug)
nf->debugPrint();
ulong t = nf->numberOfNodes();
if (verbose)
cerr << "Number of nodes: " << t << endl
<< "Number of leaves: " << nf->numberOfLeaves() << endl
<< "Tree height: " << nf->getHeight() << endl;
/**
* Build TBWT
*/
if (verbose)
cerr << "Sorting nodes..." << endl;
TBWTBuilder tbwtb(nf);
tbwtb.sort(verbose, debug);
if (verbose)
cerr << "Sorting done! Saving TBWT to disk..." << endl;
/**
* Save to disk
*/
{
FILE *output = fopen(outputfile.c_str(), "wb");
if (!output)
throw std::runtime_error("builder: could not write file");
// TBWT_SAVEFILE_MSG is defined in Tools.h
if (fwrite(TBWT_SAVEFILE_MSG, sizeof(char), strlen(TBWT_SAVEFILE_MSG), output)
!= strlen(TBWT_SAVEFILE_MSG))
throw std::runtime_error("builder: file write error (msg).");
if (fwrite(&entries, sizeof(unsigned), 1, output) != 1)
throw std::runtime_error("builder: file write error (entries).");
if (fwrite(&trees, sizeof(ulong), 1, output) != 1)
throw std::runtime_error("builder: file write error (trees).");
if (fwrite(&t, sizeof(ulong), 1, output) != 1)
throw std::runtime_error("builder: file write error (t).");
BitRank *b = new BitRank(tbwtb.getLeaf(), t, true);
if (nf->numberOfLeaves() != b->rank(t-1))
{
cerr << "TBWTBuilder::getTBWT(): assert failed: number of leaves was " << nf->numberOfLeaves() << " but rank was " << b->rank(t-1) << endl;
abort();
}
b->save(output);
delete b; b = 0;
b = new BitRank(tbwtb.getLast(), t, true);
if (t - nf->numberOfLeaves() != b->rank(t-1) - 1)
{
cerr << "TBWTBuilder::getTBWT(): assert failed: number of internal nodes was " << t-nf->numberOfLeaves() << " but rank was " << b->rank(t-1) << endl;
abort();
}
b->save(output);
delete b; b = 0;
uchar *tbwt = tbwtb.getTBWTInternal();
HuffWT *hwt = HuffWT::makeHuffWT(tbwt, t-nf->numberOfLeaves());
HuffWT::save(hwt, output);
HuffWT::deleteHuffWT(hwt);
delete [] tbwt; tbwt = 0;
tbwt = tbwtb.getTBWTLeaf();
hwt = HuffWT::makeHuffWT(tbwt, nf->numberOfLeaves());
HuffWT::save(hwt, output);
HuffWT::deleteHuffWT(hwt);
delete [] tbwt; tbwt = 0;
unsigned C[256];
unsigned F[256];
tbwtb.getCF(C, F);
/**
* C is not required
* if (fwrite(C, sizeof(unsigned), 256, output) != 256)
* throw std::runtime_error("builder: file write error (C).");
*/
if (fwrite(F, sizeof(unsigned), 256, output) != 256)
throw std::runtime_error("builder: file write error (F).");
if (debug)
for (unsigned i = 0; i < 256; ++i)
if (C[i])
cerr << "C[" << i << "] = " << C[i] << ", F[" << i << "] = " << F[i] << endl;
nf->setFirstEntry(entry);
BlockArray *leafEntry = tbwtb.getLeafEntry();
leafEntry->Save(output);
delete leafEntry;
leafEntry = 0;
BlockArray *lastEntry = tbwtb.getLastEntry();
lastEntry->Save(output);
delete lastEntry;
lastEntry = 0;
fflush(output);
fclose(output);
}
/**
* Clean up
*/
// delete [] entry; already taken care of by BitRank in SimpleForest class.
delete nf;
nf = 0;
if (fp != &std::cin)
delete fp;
fp = 0;
if (verbose)
std::cerr << "Save complete. "
<< "(total wall-clock time " << std::difftime(time(NULL), wctime) << " s, "
<< std::difftime(time(NULL), wctime) / 3600 << " hours)" << endl;
return 0;
}
| [
"cle-ment@gmx.de"
] | cle-ment@gmx.de |
6a517cab87be6a5c395dc1903493472d23dcbae0 | a2111a80faf35749d74a533e123d9da9da108214 | /raw/pmbs12/pmsb13-data-20120615/sources/brbym28nz827lxic copy/717/sandbox/meyerclp/apps/dreme/dreme.h | 758601e532b83478e67e107918d597e1bc9d427d | [
"MIT"
] | permissive | bkahlert/seqan-research | f2c550d539f511825842a60f6b994c1f0a3934c2 | 21945be863855077eec7cbdb51c3450afcf560a3 | refs/heads/master | 2022-12-24T13:05:48.828734 | 2015-07-01T01:56:22 | 2015-07-01T01:56:22 | 21,610,669 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 62,115 | h | #ifndef SANDBOX_MEYERCLP_APPS_DREME_H_
#define SANDBOX_MEYERCLP_APPS_DREME_H_
#include <fstream>
#include <iostream>
#include <map>
#include <vector>
#include <math.h>
#include <seqan/basic.h>
#include <seqan/file.h>
#include <seqan/find.h>
#include <seqan/stream.h>
#include <seqan/find_motif.h>
#include <seqan/index.h>
#include <seqan/sequence.h>
#include <seqan/misc/misc_interval_tree.h>
using namespace seqan;
struct Seq
{
StringSet<CharString> ids;
unsigned c; // Anzahl der Motive, provisorisch
StringSet<String<Dna5> > seqs;//
Index< StringSet<String<Dna5> > > SArray;
unsigned seed;
unsigned int SeqsNumber;
std::map<String<Dna5>,unsigned int > seqCounter;//maps the Sequence-Kmere to a Counter for the Sequence
std::map<String<Iupac>,unsigned int> generalizedKmer;
std::map<String<Iupac>,double > SortedPValueReversed;
std::multimap<double,String<Dna5> > SortedPValue;
std::multimap<double,String<Iupac> > generalizedSortedPValue;
std::map<unsigned int,std::map<Iupac,double> > freqMatrix;
String< std::map<unsigned int,std::map<Iupac,double> > > allPWMs;
std::map<unsigned int,std::map<Iupac,double> > weightMatrix;
std::map<unsigned int, double > seqLogoMatrix;
std::map<unsigned int, double > columnEntropy;
std::map<unsigned int,std::map<Iupac,double> > InformationContentMatrix;
FrequencyDistribution<Dna5> frequencies;
/**
In BuildFrequencyMatrix werden die gefundenen Intervalle des Top-Motivs an Intervalls gehängt
Am Ende der while wird dann ein IntervallTree für jede Sequenz erzeugt, sodass im nächsten Schritt direkt geschaut werden kann ob ein Motiv mit einem schon
gefundenen überlappt
**/
typedef IntervalAndCargo<unsigned, unsigned> TInterval;
String<String<TInterval> > intervals;//String<TInterval> enthält alle Intervalle einer Sequenz. String<String<..>> enthält alle Sequenzen
String<IntervalTree<unsigned> > intervalTrees; // Tree für schnellere Suche erstellen --> String von Trees, da mehrere Sequenzen
String<unsigned> results;
double pValue;
};
struct IupacMaps
{
std::map<unsigned int,char> IupacMap;
std::map<char,unsigned int> IupacMapReversed;
std::map<char,String<Iupac> > IupacMapReplace; //stores the replacement-chars
std::map<char,String<Dna5> > IupacMapReplaceReversed;
std::map<String<Dna5>, char > IupacMapInversed;
};
struct Euklidisch_;
typedef Tag<Euklidisch_> Euklidisch;
struct Pearson_;
typedef Tag<Pearson_> Pearson;
struct Mahalanobis_;
typedef Tag<Mahalanobis_> Mahalanobis;
struct Entropy_;
typedef Tag<Entropy_> Entropy;
struct CompleteLinkage_;
typedef Tag<CompleteLinkage_> CompleteLinkage;
struct SingleLinkage_;
typedef Tag<SingleLinkage_> SingleLinkage;
struct AverageLinkage_;
typedef Tag<AverageLinkage_> AverageLinkage;
void readFastA(struct Seq &seq, CharString fname);
template <typename TStream>
void PrintFastA(TStream & stream, Seq &seq);
void initST(Seq &seq);
void PrintST(Seq &seq);
void priorFreq(Seq &seq);
void initExactKmer(Seq &seq,Seq &back,unsigned int kmer_len,unsigned int kmer_len_end);
void CountKmer(Seq &seq, Finder<Index<StringSet<String<Dna5> > > > &finder, String<Dna5> &Kmer);
void CountKmer(std::map<String<Iupac>,unsigned int > &Dna5CounterMap, Finder<Index<StringSet<String<Iupac> > > > &finder, String<Iupac> &Kmer,Seq &seq,IupacMaps &IMap);
void PrintMap(std::map<String<Dna5>,unsigned int > &Dna5CounterMap,unsigned int SeqsNumber);
void PrintMap(std::map<String<Iupac>,unsigned int > &Dna5CounterMap,unsigned int SeqsNumber);
void PrintMap(std::multimap<double,String<Dna5> > &pValueMap);
void PrintMap(std::map<String<Iupac>,unsigned int> &generalizedKmer);
void PrintMap(Seq &seq,bool foreground);
void DebugMap(Seq &seq,Seq &back,std::map<String<Dna5>,unsigned int > &sequencesCounter,std::map<String<Dna5>,unsigned int > &backgroundCounter);
void DebugMultiMap(std::map<String<Dna5>,unsigned int > &sequencesCounter,std::multimap<double,String<Dna5> > &SortedPValue);
double* logFac;
void logFactorial(unsigned int len);
double calcFET(unsigned int a,unsigned int b,unsigned int c,unsigned int d);
void modifyFET(unsigned int a,unsigned int b,unsigned int c,unsigned int d, double &pValue);
void DebugFisherExact(unsigned int a,unsigned int b,unsigned int c,unsigned int d);
void FisherExactTest(Seq &seq, Seq &back);
void FisherExactTest(std::map<String<Iupac>,unsigned int > &SequenceCounter,std::map<String<Iupac>,unsigned int > &BackgroundCounter, Seq &seq, Seq &back);
double FisherExactTest(Seq &seq, Seq &back,std::multimap<double,String<Dna5> > &GeneralizedSortedPValueTemp);
void MapIupac(IupacMaps &IMaps);
void InitGeneralization(IupacMaps &IMaps,Seq &seq, Seq &back);
void loopOverKmer(Seq &seq,String<Iupac> &temp,String<Iupac> &Kmer,Iterator<String<Iupac> >::Type &tempIt,Finder<Index<StringSet<String<Dna5> > > > &finder,unsigned int &counter,std::vector<int> &CounterV,IupacMaps &IMap);
void FindKmer(Seq &seq,String<Iupac> &temp,Finder<Index<StringSet<String<Dna5> > > > &finder,unsigned int &counter,std::vector<int> &CounterV);
void GeneralizeKmer(String<Dna5> Kmer, IupacMaps &IMaps,Seq &seq, Seq &back);
void GeneralizeKmer(String<Iupac> Kmer,std::map<String<Iupac>,unsigned int> &generalizedKmerTemp,std::map<String<Iupac>,unsigned int> &generalizedKmerBackgroundTemp,IupacMaps &IMaps,Seq &seq, Seq &back);
void estimateCounter(Seq &seq,String<Iupac> temp,String<Iupac> temp2,unsigned int &counter);
void estimateCounter(Seq &seq,std::map<String<Iupac>,unsigned int> &generalizedKmer,String<Iupac> temp,String<Iupac> temp2,unsigned int &counter);
void exactGeneralizeCount(std::multimap<double,String<Iupac> > &SortedPValueG,std::map<String<Iupac>,unsigned int > &seqCounter,std::map<String<Iupac>,unsigned int > &backCounter,Finder<Index<StringSet<String<Dna5> > > > &finder,Finder<Index<StringSet<String<Dna5> > > > &finderB,Seq &seq, Seq &back,IupacMaps &IMap);
void FindTopKmer(Seq &seq,String<Iupac> &temp,Finder<Index<StringSet<String<Dna5> > > > &finder,unsigned int &counter,std::vector<int> &CounterV);
void FindTopKmer(Seq &seq,String<Dna5> &temp,Finder<Index<StringSet<String<Dna5> > > > &finder,unsigned int &counter,std::vector<int> &CounterV);
void loopOverTopKmer( Seq &seq,String<Iupac> &temp,String<Iupac> &Kmer,Iterator<String<Iupac> >::Type &tempIt,Finder<Index<StringSet<String<Dna5> > > > &finder,unsigned int &counter,std::vector<int> &CounterV,IupacMaps &IMap);
void BuildFrequencyMatrix( Finder<Index<StringSet<String<Dna5> > > > &finder, String<Iupac> &Kmer,Seq &seq, IupacMaps &IMaps);
void BuildFrequencyMatrix( Finder<Index<StringSet<String<Dna5> > > > &finder,String<Dna5> &Kmer,Seq &seq, IupacMaps &IMaps);
void BuildWeightMatrix(Seq &seq);
void BuildInformationContentMatrix(Seq &seq);
double ComparePWM(Seq &seq,std::map<unsigned int,std::map<Iupac,double> > &freqMatrix1,std::map<unsigned int,std::map<Iupac,double> > &freqMatrix2, Entropy const & tag);
double ComparePWM(Seq &seq,std::map<unsigned int,std::map<Iupac,double> > &freqMatrix1,std::map<unsigned int,std::map<Iupac,double> > &freqMatrix2, Euklidisch const & tag);
void PWMClustering(Seq &seq);
void UpdateDistantMatrix(int n, int x, int y, std::vector<std::vector<String<double > > > &compare, CompleteLinkage const & tag);
void UpdateDistantMatrix(int n, int x, int y, std::vector<std::vector<String<double > > > &compare,std::vector<unsigned> &weights, AverageLinkage const & tag);
void minDifferenceInMatrix(unsigned n,String<double> &minDifference,std::vector<std::vector<String<double > > > compare);
void replaceKmer(Seq &seq,unsigned int stringNumber, unsigned int begin, unsigned int end);
void saveData(Seq &seq,std::ofstream &PWM);
void computesDistantMatrix(Seq &seq,std::vector<std::vector<String<double > > > &compare, unsigned allPWMsLength);
String<double> AlignPWMs(std::map<unsigned int,std::map<Iupac,double> > &freqMatrix1,std::map<unsigned int,std::map<Iupac,double> > &freqMatrix2);
void readFastA( struct Seq &seq,
CharString fname){
//########### einlesen in ids und seqs
//Variable um Sequenz und ID zu speichern
std::fstream fasta(toCString(fname), std:: ios_base::in | std::ios_base::binary);
if(!fasta.good()){
std::cerr << "Could not open file: \"" << fname << "\"" << std::endl;
std::exit(1);
}
typedef String<char,MMap<> > TMMapString;
TMMapString mmapString;
if(!open(mmapString, toCString(fname), OPEN_RDONLY))
std::exit(1);
RecordReader<TMMapString, DoublePass<Mapped> > reader(mmapString);
AutoSeqStreamFormat formatTag;
if(!checkStreamFormat(reader,formatTag)){
std::cerr<<"Could not determine file format!"<<std::endl;
std::exit(1);
}
std::cout<<"File format is "<<getAutoSeqStreamFormatName(formatTag)<<'\n';
StringSet<CharString> ids;
StringSet<String<Dna5> > seqs;//
if(read2(ids,seqs,reader,formatTag) !=0){
std::cerr<<"ERROR reading FASTA"<<std::endl;
std::exit(1);
}
seq.ids = ids;
seq.seqs = seqs;
}
template <typename TStream>
void PrintFastA(TStream & stream,
Seq &seq){
SEQAN_ASSERT_EQ(length(seq.ids), length(seq.seqs));
typedef Iterator<StringSet<CharString>, Rooted>::Type TIdIter;
typedef Iterator<StringSet<String<Dna5> >, Standard>::Type TSeqIter;//Dna5Q
TIdIter idIt =begin(seq.ids, Rooted());
TSeqIter seqIt=begin(seq.seqs, Standard());
for(;!atEnd(idIt);++idIt,++seqIt){
stream <<*idIt<<'\t'<<*seqIt<<std::endl;
}
}
void initST(Seq &seq){
//creates a index based on an enhanced suffix array
indexText(seq.SArray) = seq.seqs;
}
void PrintST(Seq &seq){
typedef Index<StringSet<String<Dna5> > > TMyIndex;//Dna5Q
Iterator<TMyIndex, BottomUp<> >::Type myIterator(seq.SArray);
for(;!atEnd(myIterator);++myIterator){
std::cout<<representative(myIterator)<<std::endl;
}
}
/***
Berechnet relative Hintergrund-Wahrscheinlichkeit von ACGT
***/
void priorFreq(Seq &seq){
typedef Iterator<StringSet<String<Dna5> >, Standard>::Type TSeqIter;
TSeqIter seqItbegin=begin(seq.seqs, Standard());
TSeqIter seqItend=end(seq.seqs, Standard());
absFreqOfLettersInSetOfSeqs(seq.frequencies,seqItbegin,seqItend);
normalize(seq.frequencies);
}
//iniate Search in Fore- and Background
void initExactKmer( Seq &seq,
Seq &back,
unsigned int kmer_len,
unsigned int kmer_len_end){
Finder<Index<StringSet<String<Dna5> > > > finder(seq.SArray);
Finder<Index<StringSet<String<Dna5> > > > finderB(back.SArray);//finder background
typedef Index< StringSet<String<Dna5> > > TMyIndex;
//kmer_len= 3;//minimal kmer-length
//kmer_len_end=8;//maximal length
if(kmer_len<1) kmer_len=3;
if(kmer_len_end<kmer_len) kmer_len_end=kmer_len+1;
//std::cout<<"kmer: "<<kmer_len<<std::endl;
//std::cout<<"end: "<<kmer_len_end<<std::endl;
typedef Iterator<StringSet<String<Dna5> > >::Type TStringSetIterator;
unsigned int slen=0;
String<Dna5> Kmer;//current Kmer
std::cout<<std::endl<<std::endl;
for(;kmer_len<=kmer_len_end;++kmer_len){//loop over all possible Kmer-length -->3-8
for(TStringSetIterator it=begin(seq.seqs);it!=end(seq.seqs);++it){//loop over all sequences
slen=length(value(it));//length of the current seq
if(slen==0) continue;
else if(slen<kmer_len) continue;
//std::cout<<"Sequence: "<<value(it)<<std::endl;
for(unsigned int i=0;i<slen-kmer_len+1;++i){//loop over all Kmere in the current sequence
Kmer=infix(value(it),i,i+kmer_len);//optimieren
//std::cout<<Kmer<<" ";
//if(Kmer[kmer_len-1]=='N'){//'AAAN'AAAA ---> AAA'NAAA'A --> after continue AAAN'AAAA'
// i+=kmer_len;
// continue;
//}
if(seq.seqCounter.find(Kmer)!=seq.seqCounter.end()) continue;// if Kmer is in the Map -->nothing to do
// //Pattern<String<Dna5> > pattern(Kmer);
// std::cout<<"count";
CountKmer(back,finderB,Kmer);
CountKmer(seq,finder,Kmer);
}
}
}
//}
}
//gets the current Kmer and searches it in the index
//max(cumulated sum of the counter)=SeqsNumber --> counts number of sequences containing the motif
void CountKmer( Seq &seq,
Finder<Index<StringSet<String<Dna5> > > > &finder,
String<Dna5> &Kmer){
std::vector<int> CounterV(seq.SeqsNumber+1,0);//counter for storing 1 or 0 for each Seq + the cumulated sum of the counter in the last field
//std::cout<<"vor while ";
clear(finder);
while(find(finder,Kmer)){//search the current Kmer in all sequences
//std::cout<<'[' <<beginPosition(finder)<<','<<endPosition(finder)<<")\t"<<infix(finder)<<std::endl;//Debug
if(seq.c>1){//nur im foreground
clear(seq.results);
findIntervals(seq.intervalTrees[beginPosition(finder).i1], beginPosition(finder).i2, endPosition(finder).i2, seq.results);
}// wenn results>0, dann überlappt das Kmer --> nicht aufzählen
if(CounterV[beginPosition(finder).i1] == 0 && length(seq.results)==0){//count number of sequences containing the motif, not the occurrences to avoid problems with self-overlapping
++CounterV[beginPosition(finder).i1];
++CounterV[seq.SeqsNumber];//last Position in CounterV is cumulated sum
}
}
seq.seqCounter[Kmer]=CounterV[seq.SeqsNumber];
CounterV.clear();
}
void loopOverKmer( Seq &seq,
String<Iupac> &temp,
String<Iupac> &Kmer,
Iterator<String<Iupac> >::Type &tempIt,
Finder<Index<StringSet<String<Dna5> > > > &finder,
unsigned int &counter,
std::vector<int> &CounterV,
IupacMaps &IMap){
String<Dna5> replace;
Iterator<String<Dna5> >::Type replaceIt;
Iterator<String<Iupac> >::Type tempIttemp;
char resetTemp;
if(tempIt==end(temp)) return;
if((*tempIt == 'A' || *tempIt == 'C' ||*tempIt == 'G' ||*tempIt == 'T')){
loopOverKmer(seq,temp,temp,++tempIt,finder,counter,CounterV,IMap);//only replace the position with a wildcard
return;
}
replace=IMap.IupacMapReplaceReversed[*tempIt];
replaceIt = begin(replace);
for(;replaceIt!=end(replace);++replaceIt){
temp = Kmer;// reset temp
resetTemp = IMap.IupacMapInversed[replace];
*tempIt = *replaceIt;
//if not end call fkt. with temp
// if end call find --> &counter
tempIttemp=tempIt;//der rekursive aufruf mit diesem, da die schleife mit tempIt weitergehen soll
if(tempIt+1!=end(temp)){
loopOverKmer(seq,temp,temp,++tempIttemp,finder,counter,CounterV,IMap);
}
if((*tempIttemp == 'A' || *tempIttemp == 'C' || *tempIttemp == 'G' || *tempIttemp == 'T' || tempIttemp == end(temp))){
FindKmer(seq,temp,finder,counter,CounterV);
}
*tempIt=resetTemp;
}
//}
}
void FindKmer( Seq &seq,
String<Iupac> &temp,
Finder<Index<StringSet<String<Dna5> > > > &finder,
unsigned int &counter,
std::vector<int> &CounterV){
clear(finder);
while(find(finder,temp)){//search the current Kmer in all sequences
//std::cout<<'[' <<beginPosition(finder)<<','<<endPosition(finder)<<")\t"<<infix(finder)<<std::endl;//Debug
if(seq.c>1){//nur im foreground
clear(seq.results);
findIntervals(seq.intervalTrees[beginPosition(finder).i1], beginPosition(finder).i2, endPosition(finder).i2, seq.results);
}
if(CounterV[beginPosition(finder).i1] == 0 && length(seq.results)==0){//count number of sequences containing the motif, not the occurrences to avoid problems with self-overlapping
//ansonsten müsste das array noch einmal durch gegangen werden und an jeder stellt !=0 ++
++CounterV[beginPosition(finder).i1];
++CounterV[seq.SeqsNumber];//last Position in CounterV is cumulated sum
++counter;
}
}
}
/*
for counting the top 100 generalizedKmere exact
todo -->template
*/
void CountKmer( std::map<String<Iupac>,unsigned int > &seqCounter,
Finder<Index<StringSet<String<Dna5> > > > &finder,
String<Iupac> &Kmer,
Seq &seq,
IupacMaps &IMap){
String<Iupac> temp;
Iterator<String<Iupac> >::Type tempIt;
temp=Kmer;
tempIt = begin(temp);
unsigned int counter=0;
std::vector<int> CounterV(seq.SeqsNumber+1,0);//counter for storing 1 or 0 for each Seq + the cumulated sum of the counter in the last field
//std::cout<<"Kmer "<<Kmer<<std::endl;
loopOverKmer(seq,temp,Kmer,tempIt,finder,counter,CounterV,IMap);
seqCounter[Kmer]=counter;
//std::cout<<Kmer<<" "<<seqCounter[Kmer]<<" ";
//std::cout<<temp<<" "<<CounterV[SeqsNumber]<<std::endl;
CounterV.clear();
/*
Der clear hier bewirkt, dass bei ASG entweder ACG oder AGG vorkommen darf,
falls beide vorkommen(in einer Sequenz) wird der counter trotzdem nur um 1 erhöht
-->Counter für AGG ist falsch, ASG stimmt jedoch wieder. Counter[AGG] --> irrelevant
-->AGG wird jedes mal wenns benötigt wird neu berechnet-->optimieren
*/
}
//void replaceKmer( Seq &seq,
// String<unsigned int> &replaceString){
//
// unsigned int beg =0;
// unsigned int endP =0;
// unsigned int Snumber =0;
//
// //std::cout<<stringNumber<<" "<<begin<<" "<<end<<std::endl;
// Iterator<String<unsigned int> >::Type StringIt;
// StringIt = begin(replaceString);
// for(;StringIt!=end(replaceString);++StringIt){
// Snumber = *StringIt;
// ++StringIt;
// beg = *StringIt;
// ++StringIt;
// endP = *StringIt;
// //std::cout<<Snumber<<" "<<beg<<" "<<endP<<std::endl;
// for(;beg<endP;++beg)
// {
// seq.seqs[Snumber][beg]='N';
// }
// //replace(seq.seqs[*StringIt],*(++StringIt),*(++StringIt),'N');
// }
//
//
//}
///////////////////////////////////
void FindTopKmer(Seq &seq,
String<Iupac> &temp,
Finder<Index<StringSet<String<Dna5> > > > &finder,
unsigned int &counter,
std::vector<int> &CounterV){
typedef IntervalAndCargo<unsigned, unsigned> TInterval;
clear(finder);
//std::cout<<temp<<" vor-while"<<std::endl;
while(find(finder,temp)){//search the current Kmer in all sequences
if(seq.c==1){//nur im ersten Schritt in Intervals speichern, danach kann direkt an den Tree angefügt werden
appendValue(seq.intervals[beginPosition(finder).i1], TInterval(beginPosition(finder).i2, endPosition(finder).i2, 0));
}
else if(seq.c>1)
addInterval(seq.intervalTrees[beginPosition(finder).i1], TInterval(beginPosition(finder).i2, endPosition(finder).i2, 0));
if(CounterV[beginPosition(finder).i1] == 0){//count number of sequences containing the motif, not the occurrences to avoid problems with self-overlapping
++CounterV[beginPosition(finder).i1];
++CounterV[seq.SeqsNumber];//last Position in CounterV is cumulated sum
++counter;
}
}
for( unsigned int k =0;k< length(temp);++k){//berechnet Frequenz der Nukleotide, wobei jedes Motiv wieder nur einmal pro Sequenz zählt!
seq.freqMatrix[k][temp[k]]+=CounterV[seq.SeqsNumber]; //GCAGCA --> counter der einzelnen wird um die gleiche anzahl hochgezählt, GCAGTA --> usw. Nicht-Wildcards haben W'keit 1
}
CounterV.clear();
}
void FindTopKmer(Seq &seq,
String<Dna5> &temp,
Finder<Index<StringSet<String<Dna5> > > > &finder,
unsigned int &counter,
std::vector<int> &CounterV){
typedef IntervalAndCargo<unsigned, unsigned> TInterval;
clear(finder);
//std::cout<<temp<<" vor-while"<<std::endl;
while(find(finder,temp)){//search the current Kmer in all sequences
if(seq.c==1){//nur im ersten Schritt in Intervals speichern, danach kann direkt an den Tree angefügt werden
appendValue(seq.intervals[beginPosition(finder).i1], TInterval(beginPosition(finder).i2, endPosition(finder).i2, 0));
}
else if(seq.c>1)
addInterval(seq.intervalTrees[beginPosition(finder).i1], TInterval(beginPosition(finder).i2, endPosition(finder).i2, 0));
if(CounterV[beginPosition(finder).i1] == 0){//count number of sequences containing the motif, not the occurrences to avoid problems with self-overlapping
++CounterV[beginPosition(finder).i1];
++CounterV[seq.SeqsNumber];//last Position in CounterV is cumulated sum
++counter;
}
}
for( unsigned int k =0;k< length(temp);++k){//berechnet Frequenz der Nukleotide, wobei jedes Motiv wieder nur einmal pro Sequenz zählt!
seq.freqMatrix[k][temp[k]]+=CounterV[seq.SeqsNumber]; //GCAGCA --> counter der einzelnen wird um die gleiche anzahl hochgezählt, GCAGTA --> usw. Nicht-Wildcards haben W'keit 1
}
CounterV.clear();
}
void loopOverTopKmer( Seq &seq,
String<Iupac> &temp,
String<Iupac> &Kmer,
Iterator<String<Iupac> >::Type &tempIt,
Finder<Index<StringSet<String<Dna5> > > > &finder,
unsigned int &counter,
std::vector<int> &CounterV,
IupacMaps &IMaps){
String<Dna5> replace;
Iterator<String<Dna5> >::Type replaceIt;
Iterator<String<Iupac> >::Type tempIttemp;
char resetTemp;//bei mehr als einer wildcard, müssen die weiter hinten liegenden nach abarbeitung resetet werden, ansonsten werden diese im nächsten schritt übergangen
if(tempIt==end(temp)) return;//&&(tempIt+1!=end(temp))
/*freq[*tempIt]=1;
freqMatrix[pos]=freq;
freqMatrix[pos]['A']=1;
freq.clear();*/
//std::cout<<" "<<*tempIt<<" ";
if((*tempIt == 'A' || *tempIt == 'C' ||*tempIt == 'G' ||*tempIt == 'T')){
loopOverTopKmer(seq,temp,temp,++tempIt,finder,counter,CounterV,IMaps);//only replace the position with a wildcard
return;//nach diesem schritt immer return, sonst gelangt man in eine loop
}
replace=IMaps.IupacMapReplaceReversed[*tempIt];
replaceIt = begin(replace);
for(;replaceIt!=end(replace);++replaceIt){
//std::cout<<" "<<temp<<" "<<Kmer<<" "<<*replaceIt<<std::endl;
temp = Kmer;// reset temp
resetTemp = IMaps.IupacMapInversed[replace]; //falls Y ersetzt wird, ist replace CT --> also resetTemp wieder Y
//std::cout<<" resetTemp "<<resetTemp<<std::endl;
*tempIt = *replaceIt;
//std::cout<<" re "<<temp<<" ";
tempIttemp=tempIt;//der rekursive aufruf mit diesem, da die schleife mit tempIt weitergehen soll
// std::cout<<" "<<temp<<" "<<Kmer<<" "<<*replaceIt<<std::endl;
if(tempIt+1!=end(temp)){
//std::cout<<"vor if "<<temp<<std::endl;
loopOverTopKmer(seq,temp,temp,++tempIttemp,finder,counter,CounterV,IMaps);
//std::cout<<*tempIttemp<<" tempittemp "<<std::endl;
}
//zu häufig aufgerufen
if((*tempIttemp == 'A' || *tempIttemp == 'C' || *tempIttemp == 'G' || *tempIttemp == 'T' || tempIttemp == end(temp))){//falls nicht, dann kann dies übersprungen werden
/**
posTemp gibt die Stelle an, an der man sich grad befindet
--> freqMatrix enthält für jede Position die W'keit für ACGT
--> counter ist die Anzahl wie oft das Wildcard Motiv insgesamt gefunden wurde
--> CounterV an letzter Stelle die Anzahl für das jeweilige nicht-Wildcard Motiv
--> bei GSAKYA z.B. als Motiv wird jedes Motiv bei 'S' vier mal gesucht(durch die anderen 2 Wildcards)
--> CounterV für 1 bis posTemp aufaddieren --> in freqMatrix und zwar für die jeweiligen *tempIt-chars
--> am Ende alle durch counter teilen --> aufpassen, für jeweilige pos gibts verschiedene counter
--> FindKmer wird nur mit ganzen aufgerufen, also alle addieren, dann ist der counter auch gleich?
**/
std::vector<int> CounterV(seq.SeqsNumber+1,0);
FindTopKmer(seq,temp,finder,counter,CounterV);
}
*tempIt=resetTemp;
//if ende von replaceIt, dann begin(replace) in temp speichern und mitübergeben--> referenz?
}
}
/***
Computes PWM
***/
void BuildFrequencyMatrix( Finder<Index<StringSet<String<Dna5> > > > &finder,
String<Iupac> &Kmer,
Seq &seq,
IupacMaps &IMaps){
//std::cout<<Kmer<<std::endl;
//freqMatrix -->unsigned int = position in Kmer, position 1 in map = prob. for A, pos. 2 = prob. for C...
String<Iupac> temp;
Iterator<String<Iupac> >::Type tempIt;
temp=Kmer;
tempIt = begin(temp);
unsigned int counter=0;
std::vector<int> CounterV(seq.SeqsNumber+1,0);
loopOverTopKmer(seq,temp,Kmer,tempIt,finder,counter,CounterV,IMaps);
CounterV.clear();
//loopOver funktionier, aber jetzt wird der counter nicht mehr richtig berechnet --> fixen + andere loop anpassen
//Durch die wildcards mehrere Vorkommen pro Sequence möglich:
//seqCounter[temp]=CounterV[seq.SeqsNumber];
//std::cout<<temp<<" "<<*replaceIt<<" ";
if(counter>0){//normalisieren des Counters
for( unsigned int k =0;k< length(temp);++k){
seq.freqMatrix[k]['A']=(seq.freqMatrix[k]['A']+seq.frequencies[0])/(counter+1);//corrected freq (with pseudocount)
seq.freqMatrix[k]['C']=(seq.freqMatrix[k]['C']+seq.frequencies[1])/(counter+1);
seq.freqMatrix[k]['G']=(seq.freqMatrix[k]['G']+seq.frequencies[2])/(counter+1);
seq.freqMatrix[k]['T']=(seq.freqMatrix[k]['T']+seq.frequencies[3])/(counter+1);
}
}
else
seq.freqMatrix.clear();
}
/**
Version für nicht generalisierte
**/
void BuildFrequencyMatrix( Finder<Index<StringSet<String<Dna5> > > > &finder,
String<Dna5> &Kmer,
Seq &seq,
IupacMaps &IMaps){
//std::cout<<Kmer<<std::endl;
//freqMatrix -->unsigned int = position in Kmer, position 1 in map = prob. for A, pos. 2 = prob. for C...
String<Iupac> temp;
Iterator<String<Iupac> >::Type tempIt;
temp=Kmer;
tempIt = begin(temp);
unsigned int counter=0;
std::vector<int> CounterV(seq.SeqsNumber+1,0);
FindTopKmer(seq,Kmer,finder,counter,CounterV);
CounterV.clear();
if(counter>0){//normalisieren des Counters
for( unsigned int k =0;k< length(temp);++k){
seq.freqMatrix[k]['A']=(seq.freqMatrix[k]['A']+seq.frequencies[0])/(counter+1);//corrected freq (with pseudocount)
seq.freqMatrix[k]['C']=(seq.freqMatrix[k]['C']+seq.frequencies[1])/(counter+1);
seq.freqMatrix[k]['G']=(seq.freqMatrix[k]['G']+seq.frequencies[2])/(counter+1);
seq.freqMatrix[k]['T']=(seq.freqMatrix[k]['T']+seq.frequencies[3])/(counter+1);
}
}
else
seq.freqMatrix.clear();
}
//////////////////////////////////////
//FreqMatrix output
void PrintMap( Seq &seq,
bool foreground){
std::map<Iupac,double> freq;
std::cout<<std::endl;
if(foreground)
std::cout<<"foreground: "<<std::endl;
else
std::cout<<"background: "<<std::endl;
for(unsigned int j=0;j<length(seq.freqMatrix);++j){
freq=seq.freqMatrix[j];
std::cout<<"Position: "<<j<<" A: "<<freq['A']<<std::endl;
std::cout<<"Position: "<<j<<" C: "<<freq['C']<<std::endl;
std::cout<<"Position: "<<j<<" G: "<<freq['G']<<std::endl;
std::cout<<"Position: "<<j<<" T: "<<freq['T']<<std::endl;
std::cout<<std::endl;
}
}
void BuildWeightMatrix(Seq &seq){
for(unsigned int j=0;j<length(seq.freqMatrix);++j){
seq.weightMatrix[j]['A'] = log(seq.freqMatrix[j]['A']/seq.frequencies[0]);
seq.weightMatrix[j]['C'] = log(seq.freqMatrix[j]['C']/seq.frequencies[1]);
seq.weightMatrix[j]['G'] = log(seq.freqMatrix[j]['G']/seq.frequencies[2]);
seq.weightMatrix[j]['T'] = log(seq.freqMatrix[j]['T']/seq.frequencies[3]);
}
}
void saveData(Seq &seq,std::ofstream &PWM){
PWM.open("PWM",std::ios::out|std::ios::app);
for(unsigned i=0;i<length(seq.freqMatrix);++i){
PWM<<seq.freqMatrix[i]['A'];
write(PWM," ");
}
write(PWM,"\r\n");// windows
PWM.close();
PWM.open("PWM",std::ios::out|std::ios::app);
for(unsigned i=0;i<length(seq.freqMatrix);++i){
PWM<<seq.freqMatrix[i]['C'];
write(PWM," ");
}
write(PWM,"\r\n");
PWM.close();
PWM.open("PWM",std::ios::out|std::ios::app);
for(unsigned i=0;i<length(seq.freqMatrix);++i){
PWM<<seq.freqMatrix[i]['G'];
write(PWM," ");
}
write(PWM,"\r\n");
PWM.close();
PWM.open("PWM",std::ios::out|std::ios::app);
for(unsigned i=0;i<length(seq.freqMatrix);++i){
PWM<<seq.freqMatrix[i]['T'];
write(PWM," ");
}
write(PWM,"\r\n");
PWM.close();
}
void BuildInformationContentMatrix(Seq &seq){
double e = 3/(2*log(2)*seq.SeqsNumber);//4-1 = 3, 4= Anzahl Nukleotide --> small-error correction
for(unsigned int j=0;j<length(seq.freqMatrix);++j){
seq.InformationContentMatrix[j]['A'] = seq.freqMatrix[j]['A']*seq.weightMatrix[j]['A'];
seq.InformationContentMatrix[j]['C'] = seq.freqMatrix[j]['C']*seq.weightMatrix[j]['C'];
seq.InformationContentMatrix[j]['G'] = seq.freqMatrix[j]['G']*seq.weightMatrix[j]['G'];
seq.InformationContentMatrix[j]['T'] = seq.freqMatrix[j]['T']*seq.weightMatrix[j]['T'];
seq.seqLogoMatrix[j]= 2- (-(seq.InformationContentMatrix[j]['A']+seq.InformationContentMatrix[j]['C']+seq.InformationContentMatrix[j]['G']+seq.InformationContentMatrix[j]['T'])+ e);
}
}
double ComparePWM(std::map<Iupac,double> &freqMatrix1,std::map<Iupac,double> &freqMatrix2, Entropy const & tag){
/****
Für die übergebenen Spalten der Matrizen wird die Entropy berechnet
Eintrag ist = 0, wenn die Werte identisch sind. Je größer die Zahl, desto unterschiedlicher die Werte
Was wenn Wert = Hintergrundverteilung? --> Eintrag wäre = 0, obwohl das nichts mit dem Motiv zu tun hat
Für jede Spalte berechnen und durch Spaltenanzahl teilen --> im Nachhinein
****/
double columnEntropy=0;
columnEntropy = freqMatrix1['A']*log(freqMatrix1['A']/freqMatrix2['A']);
columnEntropy += freqMatrix1['C']*log(freqMatrix1['C']/freqMatrix2['C']);
columnEntropy += freqMatrix1['G']*log(freqMatrix1['G']/freqMatrix2['G']);
columnEntropy += freqMatrix1['T']*log(freqMatrix1['T']/freqMatrix2['T']);
columnEntropy += freqMatrix2['A']*log(freqMatrix2['A']/freqMatrix1['A']);
columnEntropy += freqMatrix2['C']*log(freqMatrix2['C']/freqMatrix1['C']);
columnEntropy += freqMatrix2['G']*log(freqMatrix2['G']/freqMatrix1['G']);
columnEntropy += freqMatrix2['T']*log(freqMatrix2['T']/freqMatrix1['T']);
columnEntropy = columnEntropy/2;
return columnEntropy;
}
double ComparePWM(std::map<Iupac,double> &freqMatrix1,std::map<Iupac,double> &freqMatrix2, Euklidisch const & tag){
double columnEntropy = 0;
columnEntropy = (freqMatrix1['A'] - freqMatrix2['A'])*(freqMatrix1['A'] - freqMatrix2['A']);
columnEntropy += (freqMatrix1['C'] - freqMatrix2['C'])*(freqMatrix1['C'] - freqMatrix2['C']);
columnEntropy += (freqMatrix1['G'] - freqMatrix2['G'])*(freqMatrix1['G'] - freqMatrix2['G']);
columnEntropy += (freqMatrix1['T'] - freqMatrix2['T'])*(freqMatrix1['T'] - freqMatrix2['T']);
columnEntropy = sqrt(columnEntropy);
return columnEntropy;
}
/****
Speichert die jeweiligen Mittelwerte der 2 übergebenen Matrizen
****/
void BuildMeanOf2PWMs(Seq &seq,std::map<unsigned int,std::map<Iupac,double> > &freqMatrix1,std::map<unsigned int,std::map<Iupac,double> > &freqMatrix2){
for(unsigned int j=0;j<length(freqMatrix1);++j){
freqMatrix1[j]['A'] = (freqMatrix1[j]['A']+freqMatrix2[j]['A'])/2;
freqMatrix1[j]['C'] = (freqMatrix1[j]['C']+freqMatrix2[j]['C'])/2;
freqMatrix1[j]['G'] = (freqMatrix1[j]['G']+freqMatrix2[j]['G'])/2;
freqMatrix1[j]['T'] = (freqMatrix1[j]['T']+freqMatrix2[j]['T'])/2;
}
}
void UpdateDistantMatrix(int n, int x, int y, std::vector<std::vector<String<double> > > &compare, CompleteLinkage const & tag ){
/****
Updates the distance with Complete Linkage
Replaces PWM x with the new one
****/
unsigned j;
for (j = 0; j < x; j++)
compare[x][j][0] = std::max(compare[y][j][0],compare[x][j][0]);
for (j = x+1; j < y; j++)
compare[j][x][0] = std::max(compare[y][j][0],compare[j][x][0]);
for (j = y+1; j < n; j++)
compare[j][x][0] = std::max(compare[j][y][0],compare[j][x][0]);
for (j = 0; j < y; j++) compare[y][j][0] = compare[n-1][j][0];
for (j = y+1; j < n-1; j++) compare[j][y][0] = compare[n-1][j][0];
}
void UpdateDistantMatrix(int n, int x, int y, std::vector<std::vector<String<double> > > &compare,std::vector<unsigned> &weights, AverageLinkage const & tag ){
/***
Die alten Einträge gewichtet addieren --> Gewichte am Anfang =1 ^= Clustergröße
Zur Normierung durch die addierten Gewichte teilen
***/
unsigned j;
unsigned sumOfweights = weights[x] + weights[y];
for (j = 0; j < x; j++)
compare[x][j][0] = (compare[y][j][0]*weights[y]+compare[x][j][0]*weights[x])/sumOfweights;
for (j = x+1; j < y; j++)
compare[j][x][0] = (compare[y][j][0]*weights[y]+compare[j][x][0]*weights[x])/sumOfweights;
for (j = y+1; j < n; j++)
compare[j][x][0] = (compare[j][y][0]*weights[y]+compare[j][x][0]*weights[x])/sumOfweights;
for (j = 0; j < y; j++) compare[y][j][0] = compare[n-1][j][0];
for (j = y+1; j < n-1; j++) compare[j][y][0] = compare[n-1][j][0];
weights[x]=sumOfweights;
for(j=0;j+y<length(weights)-1;++j)
weights[y+j]=weights[y+j+1];
}
void minDifferenceInMatrix(unsigned n,String<double> &minDifference,std::vector<std::vector<String<double> > > compare){
minDifference[0]=0;
for(unsigned i=0;i<n-1;++i){
for(unsigned j=i+1;j<n;++j){
if(minDifference[0]==0 || minDifference[0]>compare[j][i][0]){
minDifference[0]=compare[j][i][0];
minDifference[1]=i;
minDifference[2]=j;
std::cout<<i<<" "<<j<<" "<<compare[j][i][0];
}
}
}
std::cout<<std::endl<<minDifference[0]<<" "<<minDifference[1]<<" "<<minDifference[2]<<std::endl<<std::endl;
}
void computesDistantMatrix(Seq &seq,std::vector<std::vector<String<double> > > &compare, unsigned allPWMsLength){
unsigned j;
unsigned i;
for(i=0;i<allPWMsLength-1;++i){//computes distances with ComparePWM and saves it in the matrix compare
for( j=i+1;j<allPWMsLength;++j){
compare[j][i]=AlignPWMs(seq.allPWMs[i],seq.allPWMs[j]);
}
}
}
void PWMClustering(Seq &seq){
String<double> minDifference;
String<int> traceback;
resize(minDifference,3);
minDifference[0]=0;
unsigned allPWMsLength=length(seq.allPWMs);
std::vector<std::vector<String<double> > > compare(allPWMsLength, std::vector<String<double> >(allPWMsLength));
std::vector<int> clusterId(allPWMsLength);
unsigned j;
for (j = 0; j < allPWMsLength; j++) clusterId[j] = j;//to assign which PWM is in which cluster
/***
Average Linkage:
***/
std::vector<unsigned> weights(allPWMsLength,1);
//vorher per local alignment feststellen wo die beste Überlappung ist!
computesDistantMatrix(seq,compare,allPWMsLength);
for(unsigned n=allPWMsLength;n>1 && minDifference[0]<0.8;--n){//treshold noch bestimmen
minDifferenceInMatrix(n,minDifference,compare);
BuildMeanOf2PWMs(seq,seq.allPWMs[int(minDifference[1])],seq.allPWMs[int(minDifference[2])]);//bildet aus 2PWMs die Mittelwerte und speichert sie in
for(unsigned k=0;k<allPWMsLength-1;++k){
for(unsigned l=k+1;l<allPWMsLength;++l){
std::cout<<compare[l][k][0]<<" ";
}
std::cout<<std::endl;
}
std::cout<<std::endl;
UpdateDistantMatrix(n,int(minDifference[1]),int(minDifference[2]),compare,weights,AverageLinkage());
appendValue(traceback,clusterId[int(minDifference[1])]);
appendValue(traceback,clusterId[int(minDifference[2])]);
std::cout<<"clusterId: "<<clusterId[0]<<" "<<clusterId[1]<<" "<<clusterId[2]<<" "<<n<<" "<<allPWMsLength<<std::endl;
clusterId[int(minDifference[1])]=n-allPWMsLength-1;
for(j=0;j+minDifference[2]<allPWMsLength-1;++j)
clusterId[int(minDifference[2])+j]=clusterId[int(minDifference[2])+j+1];
std::cout<<"clusterId: "<<clusterId[0]<<" "<<clusterId[1]<<" "<<clusterId[2]<<std::endl;
//Update ClusterIds
for(unsigned k=0;k<allPWMsLength-1;++k){
for(unsigned l=k+1;l<allPWMsLength;++l){
std::cout<<compare[l][k][0]<<" ";
}
std::cout<<std::endl;
}
std::cout<<std::endl;
}
clear(clusterId);
clear(minDifference);
Iterator<String<int> >::Type tracebackIt;
std::cout<<"Traceback: "<<std::endl;
for(tracebackIt=begin(traceback);tracebackIt!=end(traceback);++tracebackIt){
std::cout<<*tracebackIt<<" ";
++tracebackIt;
std::cout<<*tracebackIt<<std::endl;
}
}
/*Prints the Mapping:
Kmer Seq1 Seq2 ... Seqn CumulatedCounter
-->Template
*/
void PrintMap( std::map<String<Dna5>,unsigned int> &Dna5CounterMap,
unsigned int SeqsNumber){
std::cout<<std::endl;
std::map<String<Dna5>,unsigned int>::iterator MapIterator;
for(MapIterator=Dna5CounterMap.begin(); MapIterator !=Dna5CounterMap.end();++MapIterator){
std::cout<<(*MapIterator).first<<" ";
std::cout<<(*MapIterator).second<<" ";
std::cout<<std::endl;
}
}
void PrintMap( std::map<String<Iupac>,unsigned int > &Dna5CounterMap,
unsigned int SeqsNumber){
std::cout<<std::endl;
std::map<String<Iupac>,unsigned int >::iterator MapIterator;
for(MapIterator=Dna5CounterMap.begin(); MapIterator !=Dna5CounterMap.end();++MapIterator){
std::cout<<(*MapIterator).first<<" ";
std::cout<<(*MapIterator).second<<" ";
std::cout<<std::endl;
}
}
void PrintMap(std::multimap<double,String<Dna5> > &pValueMap){
std::multimap<double,String<Dna5> >::iterator MapIterator;
for(MapIterator=pValueMap.begin();MapIterator !=pValueMap.end();++MapIterator){
std::cout<<(*MapIterator).first<<" ";
std::cout<<(*MapIterator).second<<std::endl;
}
}
void PrintMap(std::multimap<double,String<Iupac> > &pValueMap){
std::multimap<double,String<Iupac> >::iterator MapIterator;
//std::cout<<pValueMap.size()<<std::endl;
int i=0;
for(MapIterator=pValueMap.begin();MapIterator !=pValueMap.end() && i<10;++MapIterator,++i){
std::cout<<(*MapIterator).first<<" ";
std::cout<<(*MapIterator).second<<std::endl;
}
}
//to print the generalizedKmerMap
void PrintMap(std::map<String<Iupac>,unsigned int> &generalizedKmer){
std::map<String<Iupac>, unsigned int>::iterator MapIterator;
int i=0;
for(MapIterator=generalizedKmer.begin();MapIterator!=generalizedKmer.end() && i<20;++MapIterator,++i){
std::cout<<(*MapIterator).first<<" ";
std::cout<<(*MapIterator).second<<" ";
}
}
//Test the Map-lengths match eachother and with the sequences
void DebugMap( Seq &seq,
Seq &back,
std::map<String<Dna5>,std::vector<int> > &sequencesCounter,
std::map<String<Dna5>,std::vector<int> > &backgroundCounter){
typedef std::map<String<Dna5>,std::vector<int> > Dna5CounterMap;
Dna5CounterMap::iterator MapIterator;
MapIterator=sequencesCounter.begin();
Dna5CounterMap::iterator MapIteratorB;
MapIteratorB=backgroundCounter.begin();
SEQAN_ASSERT_EQ(length(sequencesCounter),length(backgroundCounter));
SEQAN_ASSERT_EQ(length((*MapIterator).second),(length(seq.ids)+1));//+1, because of the last field in vector
SEQAN_ASSERT_EQ(length((*MapIteratorB).second),(length(back.ids)+1));
//std::cout<<length(sequencesCounter)<<std::endl;
//std::cout<<length((*MapIterator).second)<<std::endl;
//std::cout<<length(backgroundCounter)<<std::endl;
//std::cout<<length((*MapIteratorB).second)<<std::endl;
//std::cout<<length(seq.ids)<<std::endl;
//std::cout<<length(back.ids)<<std::endl;
}
void DebugMultiMap( std::map<String<Dna5>,std::vector<int> > &sequencesCounter,
std::multimap<double,String<Dna5> > &SortedPValue){
SEQAN_ASSERT_EQ(length(sequencesCounter),SortedPValue.size());
}
void logFactorial(unsigned int len){
double* p;
unsigned int i=1;
p = (double*)malloc(sizeof(double)*(len+1));
p[0]=0;
for(;i<=len;++i){
p[i]= p[i-1] + log(i);
}
logFac =p;
}
double calcFET( unsigned int a,
unsigned int b,
unsigned int c,
unsigned int d){
return exp(logFac[a+b] + logFac[c+d] + logFac[a+c] + logFac[b+d] -
(logFac[a+b+c+d] + logFac[a]+ logFac[b] + logFac[c] +logFac[d]));
}
void modifyFET( unsigned int a,
unsigned int b,
unsigned int c,
unsigned int d,
double &pValue){
pValue= calcFET(a,b,c,d);
// //std::cout<<(*MapI).first<<" "<<pValue<<" ";
while(b!=0 && c!=0){//modify to be more extrem
++a;
--b;
--c;
++d;
pValue += calcFET(a,b,c,d);
// //std::cout<<pValue<<" ";
}
}
/***************************
log((a+b)!(c+d)!(a+c)!(b+d)!/a!b!c!d!n!) = logFactorial(a+b) + logFactorial(c+d) +
logFactorial(a+c) + logFactorial(b+d) -
(logFactorial(a+b+c+d) + logFactorial(a)+
logFactorial(b) + logFactorial(c) +
logFactorial(d))
pValue = exp(log((a+b)!(c+d)!(a+c)!(b+d)!/a!b!c!d!n!))
a=In Sequenz gefunden b=In Background gefunden
c=In Sequenz !gefunden d=In Background !gefunden
a = sequenceCounter b= backgroundCounter
a+c=SeqsNumber b+d=backgroundNumber
--> c= SeqsNumber - cumulated(sequenceCounter)
d= backgroundNumber - cumulated(backgroundCounter)
Für den einseitigen Test zusätzlich:
++a und --c
Für den zweiseitigen Test:
++a und --c
--a und ++c
****************************/
void FisherExactTest(Seq &seq,
Seq &back){
double pValue=0;
typedef std::map<String<Dna5>,unsigned int >::iterator MapIterator;
MapIterator MapI=seq.seqCounter.begin();
MapIterator MapIB=back.seqCounter.begin();
//std::cout<<(*MapI).first<<" "<<(*MapI).second.back()<<std::endl;
//std::cout<<(*MapIB).first<<" "<<(*MapIB).second.back()<<std::endl;
for(;MapI!=seq.seqCounter.end();++MapI,++MapIB){
modifyFET((*MapI).second,(*MapIB).second,(seq.SeqsNumber - (*MapI).second),(back.SeqsNumber - (*MapIB).second),pValue);
//std::cout<<pValue<<std::endl;
//SortedPValue[pValue]=(*MapI).first;
seq.SortedPValue.insert(std::pair<double,String<Dna5> > (pValue, (*MapI).first));
seq.SortedPValueReversed.insert(std::pair<String<Iupac>,double > ((*MapI).first,pValue));
}
}
//--> templates verwenden
void FisherExactTest(std::map<String<Iupac>,unsigned int > &SequenceCounter,
std::map<String<Iupac>,unsigned int > &BackgroundCounter,
Seq &seq,
Seq &back){
double pValue=0;
typedef std::map<String<Iupac>,unsigned int >::iterator MapIterator;
MapIterator MapI=SequenceCounter.begin();
MapIterator MapIB=BackgroundCounter.begin();
//std::cout<<(*MapI).first<<" "<<(*MapI).second.back()<<std::endl;
//std::cout<<(*MapIB).first<<" "<<(*MapIB).second.back()<<std::endl;
for(;MapI!=SequenceCounter.end();++MapI,++MapIB){
modifyFET((*MapI).second,(*MapIB).second,(seq.SeqsNumber - (*MapI).second),(back.SeqsNumber - (*MapIB).second),pValue);
seq.generalizedSortedPValue.insert(std::pair<double,String<Iupac> > (pValue, (*MapI).first));
seq.SortedPValueReversed.insert(std::pair< String<Iupac>,double> ((*MapI).first,pValue));
}
}
/*
Fisher-Exact-Test for generalized Kmere
*/
double FisherExactTest( Seq &seq,
Seq &back,
std::multimap<double,String<Iupac> > &GeneralizedSortedPValueTemp){
//std::cout<<"begin Fisher "<<seq.generalizedKmer.size()<<" "<<back.generalizedKmer.size()<<std::endl;
if(seq.generalizedKmer.size()==0)
return 2;
typedef std::map<String<Iupac>,unsigned int >::iterator MapIterator;
std::multimap<double,String<Iupac> >::iterator MapIterator2;
MapIterator MapI = seq.generalizedKmer.begin();
MapIterator MapIB= back.generalizedKmer.begin();
double pValue=0;
//std::cout<<generalizedKmerSequence.size();
for(;MapI!=seq.generalizedKmer.end();++MapI,++MapIB){
if((*MapI).second > seq.SeqsNumber || (*MapIB).second > back.SeqsNumber){ std::cout<<(*MapI).first<<" "<<(*MapI).second<<" "<<(*MapIB).first<<" "<<(*MapIB).second<<std::endl;}
modifyFET((*MapI).second,(*MapIB).second,seq.SeqsNumber - (*MapI).second,back.SeqsNumber - (*MapIB).second,pValue);
GeneralizedSortedPValueTemp.insert(std::pair<double,String<Iupac> > (pValue, (*MapI).first));//not seq.generalizedSortedPValue, because this is the temp one
seq.SortedPValueReversed.insert(std::pair<String<Iupac>,double > ((*MapI).first,pValue));
}
return GeneralizedSortedPValueTemp.begin()->first;
}
//void DebugFisherExact(unsigned int a,unsigned int b,unsigned int c,unsigned int d){
//
// double pValue=0;
// if(c<a || d < b){
// std::cerr<<"Cumulated Counter too large";
// exit(1);
// }
// c=c-a;
// d=d-b;
// SEQAN_ASSERT_EQ((logFactorial(2+1+4+2)),(logFactorial(9)));
//
// std::cout<<"a: "<<a<<" b: "<<b<<" c: "<<c<<" d: "<<d<<std::endl;
// pValue= logFactorial(a+b) + logFactorial(c+d) + logFactorial(a+c) + logFactorial(b+d) - (logFactorial(a+b+c+d) + logFactorial(a)+ logFactorial(b) + logFactorial(c) +logFactorial(d));
// std::cout<<"log(pValue) "<<pValue<<std::endl;
// pValue=logFactorial(a+b) + logFactorial(c+d) + logFactorial(a+c) + logFactorial(b+d) ;
// std::cout<<"the dividend: "<<pValue<<std::endl;
// pValue=- (logFactorial(2+1+4+2) + logFactorial(2)+ logFactorial(1) + logFactorial(4) +logFactorial(2));
// std::cout<<"the divisor: "<<pValue<<std::endl;
// pValue= (logFactorial(1));
// std::cout<<"logFactorial(1): "<<pValue<<std::endl;
// pValue= (logFactorial(0));
// std::cout<<"logFactorial(0): "<<pValue<<std::endl;
//
//
//}
void MapIupac(IupacMaps &IMaps ){
IMaps.IupacMap.get_allocator().allocate(16);
IMaps.IupacMap[0]='U';
IMaps.IupacMap[1]='T';
IMaps.IupacMap[2]='A';
IMaps.IupacMap[3]='W';
IMaps.IupacMap[4]='C';
IMaps.IupacMap[5]='Y';
IMaps.IupacMap[6]='M';
IMaps.IupacMap[7]='H';
IMaps.IupacMap[8]='G';
IMaps.IupacMap[9]='K';
IMaps.IupacMap[10]='R';
IMaps.IupacMap[11]='D';
IMaps.IupacMap[12]='S';
IMaps.IupacMap[13]='B';
IMaps.IupacMap[14]='V';
IMaps.IupacMap[15]='N';
IMaps.IupacMapReversed.get_allocator().allocate(16);
IMaps.IupacMapReversed['U']=0;
IMaps.IupacMapReversed['T']=1;
IMaps.IupacMapReversed['A']=2;
IMaps.IupacMapReversed['W']=3;
IMaps.IupacMapReversed['C']=4;
IMaps.IupacMapReversed['Y']=5;
IMaps.IupacMapReversed['M']=6;
IMaps.IupacMapReversed['H']=7;
IMaps.IupacMapReversed['G']=8;
IMaps.IupacMapReversed['K']=9;
IMaps.IupacMapReversed['R']=10;
IMaps.IupacMapReversed['D']=11;
IMaps.IupacMapReversed['S']=12;
IMaps.IupacMapReversed['B']=13;
IMaps.IupacMapReversed['V']=14;
IMaps.IupacMapReversed['N']=15;
IMaps.IupacMapReplace.get_allocator().allocate(14);
IMaps.IupacMapReplace['R']="CT";//in Iupac-notation R=AG --> CT left
IMaps.IupacMapReplace['Y']="AG";
IMaps.IupacMapReplace['S']="AT";
IMaps.IupacMapReplace['W']="CG";
IMaps.IupacMapReplace['K']="AC";
IMaps.IupacMapReplace['M']="GT";
IMaps.IupacMapReplace['D']="C";
IMaps.IupacMapReplace['H']="G";
IMaps.IupacMapReplace['B']="A";
IMaps.IupacMapReplace['V']="T";
IMaps.IupacMapReplace['A']="CGT";
IMaps.IupacMapReplace['C']="AGT";
IMaps.IupacMapReplace['G']="ACT";
IMaps.IupacMapReplace['T']="ACG";
IMaps.IupacMapReplaceReversed.get_allocator().allocate(11);
IMaps.IupacMapReplaceReversed['R']="AG";
IMaps.IupacMapReplaceReversed['Y']="CT";
IMaps.IupacMapReplaceReversed['S']="CG";
IMaps.IupacMapReplaceReversed['W']="AT";
IMaps.IupacMapReplaceReversed['K']="GT";
IMaps.IupacMapReplaceReversed['M']="AC";
IMaps.IupacMapReplaceReversed['D']="AGT";
IMaps.IupacMapReplaceReversed['H']="ACT";
IMaps.IupacMapReplaceReversed['B']="CGT";
IMaps.IupacMapReplaceReversed['V']="ACG";
IMaps.IupacMapReplaceReversed['N']="ACGT";
IMaps.IupacMapInversed.get_allocator().allocate(11);
IMaps.IupacMapInversed["AG"]='R';
IMaps.IupacMapInversed["CT"]='Y';
IMaps.IupacMapInversed["CG"]='S';
IMaps.IupacMapInversed["AT"]='W';
IMaps.IupacMapInversed["GT"]='K';
IMaps.IupacMapInversed["AC"]='M';
IMaps.IupacMapInversed["AGT"]='D';
IMaps.IupacMapInversed["ACT"]='H';
IMaps.IupacMapInversed["CGT"]='B';
IMaps.IupacMapInversed["ACG"]='V';
IMaps.IupacMapInversed["ACGT"]='N';
}
/* - initiate by repeatedly picking the top motifs from SortedPValue
- calls GeneralizeKmer and the EstimateFunction
*/
void InitGeneralization(IupacMaps &IMaps,
Seq &seq,
Seq &back){
std::multimap<double,String<Dna5> >::iterator MapIterator;
std::multimap<double,String<Iupac> >::iterator MapIteratorT;
std::multimap<double,String<Iupac> > generalizedSortedPValueTemp;
std::map<String<Iupac>,unsigned int> generalizedKmerTemp;
std::map<String<Iupac>,unsigned int> generalizedKmerBackgroundTemp;
unsigned int i=0;
unsigned int limit;
if(seq.SortedPValue.size()>seq.seed) limit=seq.seed;//seed meist = 100
else if(seq.SortedPValue.size()==0) return;
else limit = seq.SortedPValue.size();
for(MapIterator=seq.SortedPValue.begin();i<limit;++MapIterator,++i){//iterate over Top100
GeneralizeKmer((*MapIterator).second,IMaps,seq,back);
}
/*
- only do the next function call, if in the last at least one pValue<treshold
- call GeneralizeKmer in loop
*/
//PrintMap(seq.generalizedKmer);
//seq.generalizedSortedPValue.insert(seq.SortedPValue.begin(),seq.SortedPValue.end());
double topPValue = FisherExactTest(seq,back,generalizedSortedPValueTemp);// lowest pValue from the first generalization
double topPValueOld =seq.SortedPValue.begin()->first;//lowest pValue before generalization
while(topPValue<0.05 && topPValue<topPValueOld){//only start a new round, if the top PValue is an improvement of the old one
/*
while wird das erste mal mit generalizedKmer aufgerufen und dem tempor√§ren mapping der pValues
das tempor√§re mapping wird in das richtige mapping gemerged und gecleant, damit geschaut werden kann, ob bei den neuen pValues ein wert
über dem treshold ist --> falls nicht bricht die while ab
falls doch wird generalizedKmer kopiert und gecleant aus dem gleichen grund, damit, nur die neuen generalisierten Kmere untersucht werden
--> das Temp hier, um über alle alten zu gehen, um diese weiter zu generalisieren
*/
seq.generalizedSortedPValue.insert(generalizedSortedPValueTemp.begin(),generalizedSortedPValueTemp.end());
generalizedKmerTemp.clear();
generalizedKmerBackgroundTemp.clear();
generalizedKmerTemp=seq.generalizedKmer;
generalizedKmerBackgroundTemp=back.generalizedKmer;
back.generalizedKmer.clear();
seq.generalizedKmer.clear();
// generalizedMapIterator= generalizedKmerTemp.begin();
if(generalizedSortedPValueTemp.size()>seq.seed) limit=seq.seed;
else if(generalizedSortedPValueTemp.size()==0) return;
else limit = generalizedSortedPValueTemp.size();
i=0;//only Top100
for(MapIteratorT=generalizedSortedPValueTemp.begin();i<limit;++MapIteratorT,++i){//iterate over Top100
//Temp ums zu finden, aber das normale auch übergeben, zum neu befüllen
GeneralizeKmer((*MapIteratorT).second,generalizedKmerTemp,generalizedKmerBackgroundTemp,IMaps,seq,back);
}
generalizedSortedPValueTemp.clear();
//std::cout<<"nach for"<<std::endl;
topPValueOld =topPValue;
topPValue = FisherExactTest(seq,back,generalizedSortedPValueTemp);
//std::cout<<"nach Fisher "<<topPValue<<" "<<topPValueOld<<std::endl;
};
}
/* - gets a Kmer and replaces each position successively with each possible ambiguity Code(Iupac)
- only one wildcard per String at one time
- the unsigned int corresponds to the estimated counter
- String<Dna5> for initialization
*/
void GeneralizeKmer(String<Dna5> Kmer,
IupacMaps &IMaps,
Seq &seq,
Seq &back){
String<Iupac> temp;//temporary String --> generalizedKmer[temp]
String<Iupac> temp2;//Kmer with replaced position--> relevant for estimateCounter
Iterator<String<Iupac> >::Type tempIt;//Iterator over temp --> same length as Kmer
String<Dna5> replace = "ACGT";//replace the current position with each possible ambiguity code --> A,C,G or T
Iterator<String<Dna5> >::Type replaceIt;
unsigned int counter =0;
char tempChar;
//replaceIt = begin(replace);
temp = Kmer;
temp2=Kmer;
tempIt = begin(temp);
for(;tempIt!=end(temp);++tempIt){//loop over each position in kmer
replaceIt = begin(replace);
for(;replaceIt!=end(replace);++replaceIt){// loop over ACGT
temp = Kmer;// reset temp
if(*tempIt == *replaceIt) continue; // there is no Iupac for "AA", in return "AG" = "R"
//std::cout<<temp<<" ";
tempChar =*tempIt;//stores the current char because of temp2
*tempIt=*replaceIt;
temp2=temp;//temp2 ist nun das mit dem char für die neue wildcard
*tempIt=tempChar;//temp wieder das alte, wird aber im nächsten schritt mit einer neuen wildcard ergänzt
*tempIt =IMaps.IupacMap[IMaps.IupacMapReversed[*tempIt] + IMaps.IupacMapReversed[*replaceIt]];//compute Iupac-letter--> A + G = R and replace the current location in temp
//std::cout<<Kmer<<" "<<temp<<" "<<temp2<<std::endl;
if(seq.generalizedKmer.find(temp)!=seq.generalizedKmer.end()) continue;// if Kmer is in the Map -->nothing to do
//estimateCounter mit Kmer und temp2 aufrufen --> Kmer=AAA temp2=TAA temp=WAA
estimateCounter(seq,Kmer,temp2,counter);
seq.generalizedKmer[temp]=counter;//temp ist das neue motiv
estimateCounter(back,Kmer,temp2,counter);
back.generalizedKmer[temp]=counter;
}
}
//PrintMap(seq.generalizedKmer);
}
/* - the same as above except that each String has already a wildcard
*/
void GeneralizeKmer(String<Iupac> Kmer,
std::map<String<Iupac>,unsigned int> &generalizedKmerTemp,
std::map<String<Iupac>,unsigned int> &generalizedKmerBackgroundTemp,
IupacMaps &IMaps,
Seq &seq,
Seq &back){
String<Iupac> temp;//temporary String --> generalizedKmer[temp]
String<Iupac> temp2;//Kmer with replaced position--> relevant for estimateCounter
Iterator<String<Iupac> >::Type tempIt;//Iterator over temp --> same length as Kmer
String<Iupac> replace;
Iterator<String<Iupac> >::Type replaceIt;
unsigned int counter =0;
char tempChar;
temp = Kmer;
tempIt = begin(temp);
//std::cout<<temp<<" ";
for(;tempIt!=end(temp);++tempIt){//loop over each position in kmer
//if(*tempIt == 'A' || *tempIt == 'C' ||*tempIt == 'G' ||*tempIt == 'T') continue;//only replace the position with a wildcard
if(*tempIt =='N')continue;//gibt nichts mehr zu ersetzen
replace=IMaps.IupacMapReplace[*tempIt];
replaceIt = begin(replace);
for(;replaceIt!=end(replace);++replaceIt){// loop over the replacement-chars, W=AT --> replace=CG
temp = Kmer;// reset temp
//std::cout<<*replaceIt<<std::endl;
tempChar =*tempIt;//stores the current char because of temp2
*tempIt=*replaceIt;//replace the current char for temp2
temp2=temp;
*tempIt=tempChar;
*tempIt =IMaps.IupacMap[IMaps.IupacMapReversed[*tempIt] + IMaps.IupacMapReversed[*replaceIt]];
if(seq.SortedPValueReversed[Kmer] >= 0.05 || seq.SortedPValueReversed[temp2] >= 0.05) continue;//only if Kmer and temp2 are significant estimate the counter
if(generalizedKmerTemp.find(temp)!=generalizedKmerTemp.end()) continue;
//std::cout<<Kmer<<" "<<temp<<" "<<temp2<<std::endl;
estimateCounter(seq,generalizedKmerTemp,Kmer,temp2,counter);
seq.generalizedKmer[temp]=counter;
estimateCounter(back,generalizedKmerBackgroundTemp,Kmer,temp2,counter);
back.generalizedKmer[temp]=counter;
//std::cout<<temp<<" "<<counter<<std::endl;
}
}
/**
- gehe über Kmer --> if ACGT continue
- else rufe IupacMapReplace auf
- -->for(;replaceIt!=end(replace);++replaceIt) --> loop über den String aus IupacMapReplace
- temp ist das neue Kmer und temp2 die neue wildcard--> estimateCounter aufrufen --> für fore- und background
- funktion wird in for-schleife aufgerufen --> geht über alle
- clear generaliedKmer vor der for-schleife
- --> wird neu befüllt und kann mit FisherExact aufgerufen werden
- SortedPValue wird berechnet (in temp) und überprüft ob noch ein wert drunter ist-->falls ja insertiere temp in den rest
- falls nein nehme die top100 und rufe exactSearch auf
**/
}
//void loopOverRecplacement(String<Iupac> &temp,String<Iupac> &temp2,String<Iupac> Kmer,Iterator<String<Iupac> >::Type tempIt,unsigned int counter){
// char tempChar;
// String<Iupac> replace;
// Iterator<String<Iupac> >::Type replaceIt;
//
// replace=IupacMapReplace[*tempIt];
// replaceIt = begin(replace);
//
// for(;replaceIt!=end(replace);++replaceIt){// loop over the replacement-chars
// temp = Kmer;// reset temp
// tempChar =*tempIt;//stores the current char because of temp2
// *tempIt=*replaceIt;//replace the current char for temp2
// temp2=temp;
// *tempIt=tempChar;
//
// *tempIt =IupacMap[IupacMapReversed[*tempIt] + IupacMapReversed[*replaceIt]];
// //only if Kmer and temp2 are significant estimate the counter
// if(generalizedKmerTemp.find(temp)!=generalizedKmerTemp.end()) continue;
// estimateCounter(SequenceCounter,generalizedKmerTemp,Kmer,temp2,counter,SeqsNumber);
// generalizedKmer[temp]=counter;
// estimateCounter(BackgroundCounter,generalizedKmerBackgroundTemp,Kmer,temp2,counter,BackgroundNumber);
// generalizedKmerBackground[temp]=counter;
// //std::cout<<temp<<" "<<counter<<std::endl;
// }
//
//}
/*
- estimates the Counter for the initial wildcard-Kmere
- SequencesCounter and BackgroundCounter
*/
void estimateCounter(Seq &seq,
String<Iupac> temp,
String<Iupac> temp2,
unsigned int &counter){
//std::cout<<temp<<" "<<temp2<<std::endl;
unsigned int RE1=seq.seqCounter.find(temp)->second;//das alte motiv aus dem letzten schritt
if(seq.seqCounter.find(temp2)!=seq.seqCounter.end()){//falls temp2 ein altes motiv ist, hat es einen counter
counter= RE1+ seq.seqCounter.find(temp2)->second - (RE1*seq.seqCounter.find(temp2)->second)/seq.SeqsNumber;
//std::cout<<temp<<" "<<temp2<<" "<<RE1<<" "<<SequenceCounter.find(temp2)->second.back()<<" "<<counter<<std::endl;
if(counter>seq.SeqsNumber){ std::cout<<"if "<<counter<<" "<<temp<<" "<<RE1<<" "<<temp2<<" "<<seq.seqCounter.find(temp2)->second<<" SeqsNumer "<<seq.SeqsNumber<<std::endl;
system("PAUSE");
}
}
else{
counter=RE1;//RE2=0, da noch nicht vorhanden
//std::cout<<"else "<<counter<<std::endl;
if(counter>seq.SeqsNumber){ std::cout<<"else "<<counter<<" "<<temp<<" "<<RE1<<" "<<temp2<<" SeqsNumer "<<seq.SeqsNumber<<std::endl;
system("PAUSE");
}
}
}
/*
- estimated the Counter for the next Kmer
*/
void estimateCounter(Seq &seq,
std::map<String<Iupac>,unsigned int> &generalizedKmer,
String<Iupac> temp,
String<Iupac> temp2,
unsigned int &counter){
if(generalizedKmer.find(temp)== generalizedKmer.end()){
std::cerr<<"Error, could not find "<<temp<<" in generalizedKmer"<<std::endl;
std::exit(1);
}
//String<Iupac>="AAWR";
unsigned int RE1=(*generalizedKmer.find(temp)).second;//the new seed RE is a Kmer with wildcard
//temp2 may be in generalizedKmer or in SequenceCounter
if(seq.seqCounter.find(temp2)!=seq.seqCounter.end()){// if temp2 is in SequenceCounter do the same as above --> has no wildcard
counter= RE1+ seq.seqCounter.find(temp2)->second- (RE1*seq.seqCounter.find(temp2)->second)/seq.SeqsNumber;
//std::cout<<temp<<" "<<temp2<<" "<<RE1<<" "<<SequenceCounter.find(temp2)->second.back()<<" "<<counter<<std::endl;
if(counter>seq.SeqsNumber){ std::cout<<"if "<<counter<<" "<<temp<<" "<<RE1<<" "<<temp2<<" "<<seq.seqCounter.find(temp2)->second<<" SeqsNumer "<<seq.SeqsNumber<<std::endl;
system("PAUSE");
}
}
else if(generalizedKmer.find(temp2)!=generalizedKmer.end()){//if temp2 has a wildcard and is found in generalizedKmer
counter= RE1+ generalizedKmer.find(temp2)->second - (RE1*generalizedKmer.find(temp2)->second)/seq.SeqsNumber;
//std::cout<<temp<<" "<<temp2<<" "<<RE1<<" "<<generalizedKmer.find(temp2)->second<<" "<<counter<<std::endl;
if(counter>seq.SeqsNumber){ std::cout<<"elif "<<counter<<" "<<temp<<" "<<RE1<<" "<<temp2<<" "<<generalizedKmer.find(temp2)->second<<" SeqsNumer "<<seq.SeqsNumber<<std::endl;
system("PAUSE");
}
}
else{//if temp2 is not found
counter= RE1;//RE2=0
if(counter>seq.SeqsNumber){ std::cout<<"else "<<counter<<" "<<temp<<" "<<RE1<<" "<<temp2<<" SeqsNumer "<<seq.SeqsNumber<<std::endl;
system("PAUSE");
}
}
}
void exactGeneralizeCount( std::map<String<Iupac>,unsigned int > &seqCounter,
std::map<String<Iupac>,unsigned int > &backCounter,
Finder<Index<StringSet<String<Dna5> > > > &finder,
Finder<Index<StringSet<String<Dna5> > > > &finderB,
Seq &seq,
Seq &back,
IupacMaps &IMap){
std::multimap<double,String<Iupac> >::iterator generalizedSortedPValueIt;
//std::map<String<Iupac>,double > generalizedSortedPValueReversed;
generalizedSortedPValueIt = seq.generalizedSortedPValue.begin();
for(unsigned int i=0;i<seq.seed && generalizedSortedPValueIt!=seq.generalizedSortedPValue.end() ;++i,++generalizedSortedPValueIt){
//std::cout<<length(seq.generalizedSortedPValue)<<" "<<seq.generalizedSortedPValue.size()<<" ";
//std::cout<<(*generalizedSortedPValueIt).second<<" ";
if(seqCounter.find((*generalizedSortedPValueIt).second)!=seqCounter.end()) continue;
CountKmer(seqCounter,finder,(*generalizedSortedPValueIt).second,seq,IMap);
CountKmer(backCounter,finderB,(*generalizedSortedPValueIt).second,back,IMap);
}
seq.generalizedSortedPValue.clear();
//PrintMap(seqCounter,seq.SeqsNumber);
FisherExactTest(seqCounter,backCounter,seq,back);//computes the pValue of each Motif due to the counter
std::cout<<std::endl;
//PrintMap(seq.generalizedSortedPValue);
seqCounter.clear();
backCounter.clear();
}
String<double> AlignPWMs(std::map<unsigned int,std::map<Iupac,double> > &freqMatrix1,std::map<unsigned int,std::map<Iupac,double> > &freqMatrix2){
int freqL1 = length(freqMatrix1);
int freqL2 = length(freqMatrix2);
std::vector<std::vector<double> > M(freqL1+1,std::vector<double>(freqL2+1));
for(unsigned i=0;i<=freqL1;++i){
for(unsigned j=0;j<=freqL2;++j){
M[i][j]=0;
}
}
//traceback wird nicht benötigt, da zwischen den anfangs- und end-gaps keine erlaubt sind
String<double> Mmax;
appendValue(Mmax,100);
appendValue(Mmax,0);
appendValue(Mmax,0);
for(unsigned i=1;i<=freqL1;++i){
for(unsigned j=1;j<=freqL2;++j){
M[i][j]=M[i-1][j-1]+ComparePWM(freqMatrix1[i-1],freqMatrix2[j-1],Entropy());//je größer, desto unterschiedlicher --> Problem: je weniger abgezogen wird, desto größer
if((i==freqL1 && j>freqL2/2 && M[i][j]/j<Mmax[0])){//auf die Länge der Überlappung normalisieren --> /j --> über die Hälfte des Kmers soll überlappen
Mmax[0]=M[i][j]/j;
Mmax[1]=i;
Mmax[2]=j;
}
else if((j==freqL2 &&i>freqL1/2 && M[i][j]/i<Mmax[0])){
Mmax[0]=M[i][j]/i;
Mmax[1]=i;
Mmax[2]=j;
}
}
std::cout<<std::endl;
}
std::cout<<std::endl;
return Mmax;
}
#endif // #ifndef SANDBOX_MEYERCLP_APPS_DREME_H_
| [
"mail@bkahlert.com"
] | mail@bkahlert.com |
efbf311bf1aa554542ef80263b1cfd0b3ad46c7e | 64058e1019497fbaf0f9cbfab9de4979d130416b | /c++/src/algo/blast/api/version.cpp | 422b333779995f239eed305df9c70cea863560af | [
"MIT"
] | permissive | OpenHero/gblastn | 31e52f3a49e4d898719e9229434fe42cc3daf475 | 1f931d5910150f44e8ceab81599428027703c879 | refs/heads/master | 2022-10-26T04:21:35.123871 | 2022-10-20T02:41:06 | 2022-10-20T02:41:06 | 12,407,707 | 38 | 21 | null | 2020-12-08T07:14:32 | 2013-08-27T14:06:00 | C++ | UTF-8 | C++ | false | false | 5,141 | cpp | /* $Id: version.cpp 363242 2012-05-15 15:00:29Z madden $
* ===========================================================================
*
* PUBLIC DOMAIN NOTICE
* National Center for Biotechnology Information
*
* This software/database is a "United States Government Work" under the
* terms of the United States Copyright Act. It was written as part of
* the author's official duties as a United States Government employee and
* thus cannot be copyrighted. This software/database is freely available
* to the public for use. The National Library of Medicine and the U.S.
* Government have not placed any restriction on its use or reproduction.
*
* Although all reasonable efforts have been taken to ensure the accuracy
* and reliability of the software and data, the NLM and the U.S.
* Government do not and cannot warrant the performance or results that
* may be obtained by using this software or data. The NLM and the U.S.
* Government disclaim all warranties, express or implied, including
* warranties of performance, merchantability or fitness for any particular
* purpose.
*
* Please cite the author in any work or product based on this material.
*
* ===========================================================================
*
* Authors: Christiam Camacho
*
*/
/// @file version.cpp
/// Implementation of the BLAST engine's version and reference classes
#include <ncbi_pch.hpp>
#include <algo/blast/core/blast_engine.h>
#include <algo/blast/api/version.hpp>
#include <sstream>
/** @addtogroup AlgoBlast
*
* @{
*/
BEGIN_NCBI_SCOPE
BEGIN_SCOPE(blast)
/// References for the various BLAST publications
static const string kReferences[(int)CReference::eMaxPublications+1] = {
// eGappedBlast
"Stephen F. Altschul, Thomas L. Madden, \
Alejandro A. Schäffer, Jinghui Zhang, Zheng Zhang, Webb Miller, and David J. \
Lipman (1997), \"Gapped BLAST and PSI-BLAST: a new generation of protein \
database search programs\", Nucleic Acids Res. 25:3389-3402.",
// ePhiBlast
"Zheng Zhang, Alejandro A. Schäffer, Webb Miller, \
Thomas L. Madden, David J. Lipman, Eugene V. Koonin, and Stephen F. \
Altschul (1998), \"Protein sequence similarity searches using patterns \
as seeds\", Nucleic Acids Res. 26:3986-3990.",
// eMegaBlast
"Zheng Zhang, Scott Schwartz, Lukas Wagner, and Webb Miller (2000), \
\"A greedy algorithm for aligning DNA sequences\", \
J Comput Biol 2000; 7(1-2):203-14.",
// eCompBasedStats
"Alejandro A. Schäffer, L. Aravind, Thomas L. Madden, Sergei Shavirin, \
John L. Spouge, Yuri I. Wolf, Eugene V. Koonin, and Stephen F. Altschul \
(2001), \"Improving the accuracy of PSI-BLAST protein database searches \
with composition-based statistics and other refinements\", Nucleic Acids \
Res. 29:2994-3005.",
// eCompAdjustedMatrices
"Stephen F. Altschul, John C. Wootton, E. Michael Gertz, Richa Agarwala, \
Aleksandr Morgulis, Alejandro A. Schäffer, and Yi-Kuo Yu (2005) \"Protein \
database searches using compositionally adjusted substitution matrices\", \
FEBS J. 272:5101-5109.",
// eIndexedMegablast
"Aleksandr Morgulis, George Coulouris, Yan Raytselis, \
Thomas L. Madden, Richa Agarwala, Alejandro A. Schäffer \
(2008), \"Database Indexing for Production MegaBLAST Searches\", \
Bioinformatics 24:1757-1764.",
// eDeltaBlast
"Grzegorz M. Boratyn, Alejandro A. Schaffer, Richa Agarwala, Stephen F. Altschul, \
David J. Lipman and Thomas L. Madden (2012) \"Domain enhanced lookup time \
accelerated BLAST\", Biology Direct 7:12.",
// eMaxPublications
kEmptyStr
};
/// Pubmed URLs to retrieve the references defined above
static const string kPubMedUrls[(int)CReference::eMaxPublications+1] = {
// eGappedBlast
"http://www.ncbi.nlm.nih.gov/\
entrez/query.fcgi?db=PubMed&cmd=Retrieve&list_uids=9254694&dopt=Citation",
// ePhiBlast
"http://www.ncbi.nlm.nih.gov/\
entrez/query.fcgi?db=PubMed&cmd=Retrieve&list_uids=9705509&dopt=Citation",
// eMegaBlast
"http://www.ncbi.nlm.nih.gov/\
entrez/query.fcgi?db=PubMed&cmd=Retrieve&list_uids=10890397&dopt=Citation",
// eCompBasedStats
"http://www.ncbi.nlm.nih.gov/\
entrez/query.fcgi?db=PubMed&cmd=Retrieve&list_uids=11452024&dopt=Citation",
// eCompAdjustedMatrices
"http://www.ncbi.nlm.nih.gov/\
entrez/query.fcgi?db=PubMed&cmd=Retrieve&list_uids=16218944&dopt=Citation",
// eIndexedMegablast
"http://www.ncbi.nlm.nih.gov/pubmed/18567917",
// eDeltaBlast
"http://www.ncbi.nlm.nih.gov/pubmed/22510480",
// eMaxPublications
kEmptyStr
};
string
CReference::GetString(EPublication pub)
{
return kReferences[(int) pub];
}
string
CReference::GetHTMLFreeString(EPublication pub)
{
string pub_string = GetString(pub);
string::size_type offset = pub_string.find("ä");
if (offset != string::npos)
pub_string.replace(offset, 6, "a");
return pub_string;
}
string
CReference::GetPubmedUrl(EPublication pub)
{
return kPubMedUrls[(int) pub];
}
END_SCOPE(blast)
END_NCBI_SCOPE
/* @} */
| [
"zhao.kaiyong@gmail.com"
] | zhao.kaiyong@gmail.com |
e640252cbe72e57d898dbfa08d22087d7b03eb62 | 61c263eb77eb64cf8ab42d2262fc553ac51a6399 | /src/Command.cpp | 159a8add0c9b9be9607029b56d9a413ea0dd41b2 | [] | no_license | ycaihua/fingermania | 20760830f6fe7c48aa2332b67f455eef8f9246a3 | daaa470caf02169ea6533669aa511bf59f896805 | refs/heads/master | 2021-01-20T09:36:38.221802 | 2011-01-23T12:31:19 | 2011-01-23T12:31:19 | 40,102,565 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,118 | cpp | #include "global.h"
#include "Command.h"
#include "RageUtil.h"
#include "RageLog.h"
#include "arch/Dialog/Dialog.h"
#include "Foreach.h"
RString Command::GetName() const
{
if (m_vsArgs.empty())
return RString();
RString s = m_vArgs[0];
Trim(s);
return s;
}
Command::Arg Command::GetArg(unsigned index) const
{
Arg a;
if (index < m_vsArgs.size())
a.s = m_vsArgs[index];
return a;
}
void Command::Load(const RString& sCommand)
{
m_vsArgs.clear();
split(sCommand, ",", m_vsArgs, false);
}
RString Command::GetOriginalCommandString() const
{
return join(",", m_vsArgs);
}
static void SplitWithQuotes(const RString sSource, const char Delimitor, vector<RString>& asOut, const bool bIgnoreEmpty)
{
if (sSource.empty())
return;
size_t startpos = 0;
do
{
size_t pos = startpos;
while (pos < sSource.size())
{
if (sSource[pos] == Delimitor)
break;
if (sSource[pos] == '"' || sSource[pos] == '\'')
{
pos = sSource.find(sSource[pos], pos + 1);
if (pos == string::npos)
pos = sSource.size();
else
++pos;
}
else
++pos;
}
if (pos - startpos > 0 || !bIgnoreEmpty)
{
if (startpos == 0 && pos - startpos == sSource.size())
asOut.push_back(sSource);
else
{
const RString AddCString = sSource.substr( startpos, pos-startpos );
asOut.push_back( AddCString );
}
}
startpos = pos + 1;
} while (startpos <= sSource.size());
}
RString Commands::GetOriginalCommandString() const
{
RString s;
FOREACH_CONST(Command, v, c)
s += c->GetOriginalCommandString();
return s;
}
void ParseCommands(const RString& sCommands, Commands& vCommandOut)
{
vector<RString> vsCommands;
SplitWithQuotes(sCommands, ";", vsCommands, true);
vCommandsOut.resize(vsCommands.size());
for (unsigned i = 0; i < vsCommands.size(); i++)
{
Command& cmd = vCommandOut.v[i];
cmd.Load(vsCommands[i]);
}
}
Commands ParseCommands(const RString& sCommands)
{
Commands vCommands;
ParseCommands(sCommands, vCommands);
return vCommands;
}
| [
"davidleee121@gmail.com"
] | davidleee121@gmail.com |
573880833bcd9ee26a4129db4739841cb6406efa | 421120321d272ed949e749a671b6318b0817b40f | /Mino.cpp | 45b5ba7fff63e3343aff7f388a8c6a7634b27ed8 | [] | no_license | nckuharden/lab7 | 525d6584672b7e148f1733df7710097d79431246 | 58c2b8f3c43edeaf805ac15a70f320edaca6d60b | refs/heads/master | 2021-01-19T13:30:51.427410 | 2015-06-30T19:18:35 | 2015-06-30T19:18:35 | 38,327,889 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 192 | cpp | #include "Mino.h"
Mino::Mino(int mri):max_ri(mri) {};
Mino& Mino::turn()
{
rotate_index=(rotate_index>=max_ri)?0:rotate_index+1;
return *this;
}
void Mino::rotatez()
{
rotate_index=0;
}
| [
"ilovemyself1725@gmail.com"
] | ilovemyself1725@gmail.com |
b27950ecd13e166d3df51825c1993179357fd6ec | 7391feeb5b8e31f982422bdd74517e954d8c955e | /Foundation/testsuite/src/FormatTest.h | 94328d462d724862f3528dae1a087309dfff9c68 | [
"BSL-1.0"
] | permissive | AppAnywhere/agent-sdk | 62d762d0424fc2e8d4a98b79fb150e635adedd4d | c5495c4a1d892f2d3bca5b82a7436db7d8adff71 | refs/heads/master | 2021-01-11T15:22:01.406793 | 2016-09-01T16:36:20 | 2016-09-01T16:36:20 | 80,341,203 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 686 | h | //
// FormatTest.h
//
// $Id: //poco/1.7/Foundation/testsuite/src/FormatTest.h#1 $
//
// Definition of the FormatTest class.
//
// SPDX-License-Identifier: BSL-1.0
//
#ifndef FormatTest_INCLUDED
#define FormatTest_INCLUDED
#include "Poco/Foundation.h"
#include "CppUnit/TestCase.h"
class FormatTest: public CppUnit::TestCase
{
public:
FormatTest(const std::string& name);
~FormatTest();
void testChar();
void testInt();
void testBool();
void testAnyInt();
void testFloatFix();
void testFloatSci();
void testString();
void testMultiple();
void testIndex();
void setUp();
void tearDown();
static CppUnit::Test* suite();
private:
};
#endif // FormatTest_INCLUDED
| [
"guenter.obiltschnig@appinf.com"
] | guenter.obiltschnig@appinf.com |
0ad49cfa1cdafe46d86dc180784d2968a2a5eead | 51b0c7cff3ad2e0de16b075290151d38632c6b14 | /lib/BddUnity/src/BddUnity/Entry/Test/Params.hpp | b8e4e41cae0dffb7d24fa513371483d86a2ee21a | [] | no_license | pghalliday/platformio-testing | 914301e97e2df48faa89ce651727efe823e00ee4 | 7759156f3f821167c28a233eb12d2d5f89efe6f1 | refs/heads/master | 2022-10-12T01:58:13.004973 | 2020-06-08T01:05:45 | 2020-06-08T18:30:32 | 269,110,261 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 393 | hpp | #pragma once
#include "../Interface.hpp"
namespace BddUnity {
namespace Entry {
namespace Test {
struct Params {
const char * label;
const int line;
Memory::Pool::Interface<Interface, Callback::Params> & callbackPool;
Memory::Pool::Interface<Interface, AsyncCallback::Params> & asyncCallbackPool;
Interface * entry;
};
}
}
}
| [
"pghalliday@gmail.com"
] | pghalliday@gmail.com |
cf90784b26bfdf932bab78040fb5ce6d6d295b5d | 12840d008d17df59a37997691774fa87e5f227be | /zhongzihao-personal/codeforces/475/C.cpp | a9b4455018e288859ad8e08efdaa89204bbe38d0 | [] | no_license | clatisus/ACM-ICPC-Team-Archive | 4b6c3d2dfb300f928f4f201ae156bde5f871a734 | 7410ddfa81de8750668d8ac2c334987b5af7e613 | refs/heads/master | 2022-07-21T13:03:22.768792 | 2020-01-04T11:30:43 | 2020-01-04T11:30:43 | 136,951,655 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,562 | cpp | #include<bits/stdc++.h>
typedef long long ll;
typedef std::pair <ll, ll> pii;
std::map <ll, std::vector <pii>> Hash;
int main(){
int n;
scanf("%d", &n);
for (int i = 0; i < n; ++ i){
ll w, h, c;
scanf("%I64d%I64d%I64d", &w, &h, &c);
Hash[w].push_back({h, c});
}
for (auto &u : Hash){
std::sort(u.second.begin(), u.second.end());
}
for (auto &u : Hash){
if (u.second.size() != Hash.begin() -> second.size()){
puts("0");
return 0;
}
}
for (int i = 0, sz = Hash.begin() -> second.size(); i < sz; ++ i){
for (auto &u : Hash){
if (u.second[i].first != Hash.begin() -> second[i].first){
puts("0");
return 0;
}
ll x0 = u.second[i].second, y0 = u.second[0].second;
ll x1 = Hash.begin() -> second[i].second, y1 = Hash.begin() -> second[0].second;
ll gcd0 = std::__gcd(x0, y0), gcd1 = std::__gcd(x1, y1);
x0 /= gcd0, y0 /= gcd0;
x1 /= gcd1, y1 /= gcd1;
if (x0 != x1 || y0 != y1){
puts("0");
return 0;
}
}
}
ll lcm0 = 1;
ll value = Hash.begin() -> second[0].second;
for (auto &u : Hash.begin() -> second){
ll x = value / std::__gcd(value, u.second);
lcm0 = x / std::__gcd(x, lcm0) * lcm0;
}
ll lcm1 = 1;
for (auto &u : Hash){
ll x = value / std::__gcd(value, u.second[0].second);
lcm1 = x / std::__gcd(x, lcm1) * lcm1;
}
int ans = 0;
std::set <ll> fact;
for (ll x = 1; x * x <= value; ++ x){
if (value % x == 0){
fact.insert(x);
fact.insert(value / x);
}
}
for (auto u : fact){
ans += u % lcm0 == 0 && value / u % lcm1 == 0;
}
printf("%d\n", ans);
return 0;
}
| [
"clatisus@gmail.com"
] | clatisus@gmail.com |
3c408174fafb1ef3c9c0c883e0f6bdce1abee90f | 6864dcda3dad783f2a87ce789427b362412a2264 | /inc/dictos/net/Address.hpp | 0c91e870e365e7665a74d56bebac8ed63c6d7f7a | [
"BSD-2-Clause"
] | permissive | JasonDictos/dictos-net | 1af3cd6b2b68ed1281b11def335cf18324608083 | 2a8bcbf8ef67761a4d5e3ee5df2aefa6131fbf34 | refs/heads/master | 2020-03-08T04:58:17.858625 | 2018-05-25T18:24:47 | 2018-05-25T18:24:47 | 127,935,718 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,591 | hpp | #pragma once
namespace dictos::net {
inline Address::Address(const Address &addr)
{
operator = (addr);
}
inline Address::Address(Address &&addr)
{
operator = (std::move(addr));
}
inline Address &Address::operator = (const Address &addr)
{
if (this == &addr)
return *this;
m_protocol = addr.m_protocol;
m_address = addr.m_address;
m_port = addr.m_port;
return *this;
}
inline Address &Address::operator = (Address &&addr)
{
m_protocol = addr.m_protocol;
m_address = std::move(addr.m_address);
m_port = addr.m_port;
addr.m_protocol = PROTOCOL_TYPE::Init;
addr.m_port = 0;
addr.m_address = IpAddress();
return *this;
}
inline Address::Address(const std::string &addr)
{
operator = (addr);
}
inline Address & Address::operator = (const std::string &addr)
{
m_address = validate(addr, m_port, m_protocol);
return *this;
}
inline unsigned short Address::port() const
{
if (m_protocol == PROTOCOL_TYPE::Pipe || m_protocol == PROTOCOL_TYPE::UnixDomain)
DCORE_THROW(RuntimeError, "Address type does not support a port number");
return m_port;
}
inline std::string Address::ip() const
{
if (m_protocol != PROTOCOL_TYPE::Tcp && m_protocol != PROTOCOL_TYPE::WebSocket && m_protocol != PROTOCOL_TYPE::Ssl && m_protocol != PROTOCOL_TYPE::SslWebSocket)
DCORE_THROW(RuntimeError, "Address type does not support an ip");
return m_address.to_string();
}
inline std::string Address::__toString() const
{
if (m_port)
return string::toString(m_protocol, "://", m_address, ":", m_port);
return string::toString(m_protocol, "://", m_address);
}
inline PROTOCOL_TYPE Address::protocol() const
{
return m_protocol;
}
inline Address::operator bool () const
{
return m_protocol != PROTOCOL_TYPE::Init;
}
inline Address::IpAddress Address::validate(const std::string &__address, unsigned short &_port, TYPE &type)
{
// Extract the protocol type and look it up in the protocol registrar
auto [prefix, _address] = string::split("://", __address);
type = protocol::lookup(prefix);
// Extract the port
auto [address, port] = string::split(":", _address);
// Now we can have boost parse the ip portion
boost::system::error_code ec;
auto addr = IpAddress::from_string(address, ec);
if (ec)
DCORE_THROW(InvalidArgument, "Un-recognized address:", address, ec);
// If tcp fetch port
switch (type) {
case PROTOCOL_TYPE::Tcp:
case PROTOCOL_TYPE::Udp:
case PROTOCOL_TYPE::WebSocket:
case PROTOCOL_TYPE::SslWebSocket:
if (!port.empty())
_port = string::toNumber<unsigned short>(port);
break;
}
// And return the ip address object
return addr;
}
}
| [
"jason@dictos.com"
] | jason@dictos.com |
13a75733afb3920da137f08be2ccb8019e3290fa | 6909fd482f686b868bd6b021a1a676147ae35411 | /NecroDancer/NecroDancer/Stage1Beat.h | b16d441fa7ca01390a031efadb059a3fc7c8f93e | [] | no_license | SamMul815/Direct2D-API | 889612708ff4babd0c4842a78da2e19a2ca7c632 | 14faea47bd7ed0683ae92e130d3bcd63cc93c307 | refs/heads/master | 2020-04-18T04:37:15.557553 | 2019-01-23T20:06:47 | 2019-01-23T20:06:47 | 167,245,812 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 250 | h | #pragma once
#include "HeartBeat.h"
class Stage1Beat : public HeartBeat
{
public:
Stage1Beat();
~Stage1Beat();
virtual HRESULT Init(int y);
virtual void Update();
virtual void Render();
virtual void Release();
virtual void NoteLoad();
};
| [
"815youngmin@naver.com"
] | 815youngmin@naver.com |
f57d563e738b8167a5b1f3052e7d74d8242bd14a | 6a16318ae41875c771477a1279044cdc8fc11c83 | /Horoscopes/src/database/database.h | 65189be67a60c3af5a8b9babb06a842e7e4404a6 | [] | no_license | JasF/horoscopes | 81c5ad2e9809c67d16606a2e918fd96b0450dbee | 880fdf92d6cd48a808e24928dc54a106bda34ce6 | refs/heads/master | 2021-09-10T13:43:46.246063 | 2018-03-27T06:24:02 | 2018-03-27T06:24:02 | 118,770,043 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 702 | h | //
// database.h
// Horoscopes
//
// Created by Jasf on 30.10.2017.
// Copyright © 2017 Freedom. All rights reserved.
//
#ifndef database_h
#define database_h
#include "base/horobase.h"
#include "database/resultset.h"
namespace horo {
class _Database {
public:
virtual ~_Database() {}
virtual bool executeUpdate(std::string query, Json::Value parameters = Json::Value()) = 0;
virtual strong<ResultSet> executeQuery(std::string query, Json::Value parameters = Json::Value()) = 0;
virtual int64_t lastInsertRowId() const = 0;
virtual std::string lastErrorMessage()=0;
};
typedef reff<_Database> Database;
};
#endif /* database_h */
| [
"andreivoe@gmail.com"
] | andreivoe@gmail.com |
fc43c371d9df9080e1aec4ac87d2f6a7d97bdac3 | 3306ffb058ea67d4140dcbc641a735d3cafdfd68 | /src/qt/sendcoinsentry.cpp | 56125779d7ef0ca7b3c0f6d07f2b63acad958e00 | [
"MIT"
] | permissive | niobiumcoin/niobiumcoin | a98f724f3f5047ff6cdda4aba2d5e7e6ddf6fd44 | b6f3d8691231f51aa83c119740fb0971d764267a | refs/heads/master | 2019-07-12T20:14:00.837924 | 2017-11-21T19:59:34 | 2017-11-21T19:59:34 | 107,165,666 | 2 | 4 | null | null | null | null | UTF-8 | C++ | false | false | 4,641 | cpp | #include "sendcoinsentry.h"
#include "ui_sendcoinsentry.h"
#include "guiutil.h"
#include "bitcoinunits.h"
#include "addressbookpage.h"
#include "walletmodel.h"
#include "optionsmodel.h"
#include "addresstablemodel.h"
#include "stealth.h"
#include <QApplication>
#include <QClipboard>
SendCoinsEntry::SendCoinsEntry(QWidget *parent) :
QFrame(parent),
ui(new Ui::SendCoinsEntry),
model(0)
{
ui->setupUi(this);
#ifdef Q_OS_MAC
ui->payToLayout->setSpacing(4);
#endif
#if QT_VERSION >= 0x040700
/* Do not move this to the XML file, Qt before 4.7 will choke on it */
ui->addAsLabel->setPlaceholderText(tr("Enter a label for this address to add it to your address book"));
ui->payTo->setPlaceholderText(tr("Enter a Niobium address (e.g. iACLambeGgkxodKtfzM7huFXyPYWjz33Z2)"));
#endif
setFocusPolicy(Qt::TabFocus);
setFocusProxy(ui->payTo);
GUIUtil::setupAddressWidget(ui->payTo, this);
}
SendCoinsEntry::~SendCoinsEntry()
{
delete ui;
}
void SendCoinsEntry::on_pasteButton_clicked()
{
// Paste text from clipboard into recipient field
ui->payTo->setText(QApplication::clipboard()->text());
}
void SendCoinsEntry::on_addressBookButton_clicked()
{
if(!model)
return;
AddressBookPage dlg(AddressBookPage::ForSending, AddressBookPage::SendingTab, this);
dlg.setModel(model->getAddressTableModel());
if(dlg.exec())
{
ui->payTo->setText(dlg.getReturnValue());
ui->payAmount->setFocus();
}
}
void SendCoinsEntry::on_payTo_textChanged(const QString &address)
{
if(!model)
return;
// Fill in label from address book, if address has an associated label
QString associatedLabel = model->getAddressTableModel()->labelForAddress(address);
if(!associatedLabel.isEmpty())
ui->addAsLabel->setText(associatedLabel);
}
void SendCoinsEntry::setModel(WalletModel *model)
{
this->model = model;
if(model && model->getOptionsModel())
connect(model->getOptionsModel(), SIGNAL(displayUnitChanged(int)), this, SLOT(updateDisplayUnit()));
connect(ui->payAmount, SIGNAL(textChanged()), this, SIGNAL(payAmountChanged()));
clear();
}
void SendCoinsEntry::setRemoveEnabled(bool enabled)
{
ui->deleteButton->setEnabled(enabled);
}
void SendCoinsEntry::clear()
{
ui->payTo->clear();
ui->addAsLabel->clear();
ui->payAmount->clear();
ui->payTo->setFocus();
// update the display unit, to not use the default ("BTC")
updateDisplayUnit();
}
void SendCoinsEntry::on_deleteButton_clicked()
{
emit removeEntry(this);
}
bool SendCoinsEntry::validate()
{
// Check input validity
bool retval = true;
if(!ui->payAmount->validate())
{
retval = false;
}
else
{
if(ui->payAmount->value() <= 0)
{
// Cannot send 0 coins or less
ui->payAmount->setValid(false);
retval = false;
}
}
if(!ui->payTo->hasAcceptableInput() ||
(model && !model->validateAddress(ui->payTo->text())))
{
ui->payTo->setValid(false);
retval = false;
}
return retval;
}
SendCoinsRecipient SendCoinsEntry::getValue()
{
SendCoinsRecipient rv;
rv.address = ui->payTo->text();
rv.label = ui->addAsLabel->text();
rv.amount = ui->payAmount->value();
if (rv.address.length() > 75
&& IsStealthAddress(rv.address.toStdString()))
rv.typeInd = AddressTableModel::AT_Stealth;
else
rv.typeInd = AddressTableModel::AT_Normal;
return rv;
}
QWidget *SendCoinsEntry::setupTabChain(QWidget *prev)
{
QWidget::setTabOrder(prev, ui->payTo);
QWidget::setTabOrder(ui->payTo, ui->addressBookButton);
QWidget::setTabOrder(ui->addressBookButton, ui->pasteButton);
QWidget::setTabOrder(ui->pasteButton, ui->deleteButton);
QWidget::setTabOrder(ui->deleteButton, ui->addAsLabel);
return ui->payAmount->setupTabChain(ui->addAsLabel);
}
void SendCoinsEntry::setValue(const SendCoinsRecipient &value)
{
ui->payTo->setText(value.address);
ui->addAsLabel->setText(value.label);
ui->payAmount->setValue(value.amount);
}
void SendCoinsEntry::setAddress(const QString &address)
{
ui->payTo->setText(address);
ui->payAmount->setFocus();
}
bool SendCoinsEntry::isClear()
{
return ui->payTo->text().isEmpty();
}
void SendCoinsEntry::setFocus()
{
ui->payTo->setFocus();
}
void SendCoinsEntry::updateDisplayUnit()
{
if(model && model->getOptionsModel())
{
// Update payAmount with the current unit
ui->payAmount->setDisplayUnit(model->getOptionsModel()->getDisplayUnit());
}
}
| [
"dev@niobiumcoin.org"
] | dev@niobiumcoin.org |
f07285211331f67dceb08ae6a4a48b54ab0705d0 | c315785bb6d0076bf628157638621b9b61281b2f | /lowlvl.cpp | ba99360ccd18b1f780fd15772b0ccdd5d9bd09df | [] | no_license | nestori/aery32-lcd | c82a6878af3e7882e7b8e6b075fa6c9cbd3451d4 | e3d2abd48c1d538897a3851b1ab3cf39925a71ec | refs/heads/master | 2021-01-15T14:43:03.045520 | 2013-04-23T08:44:08 | 2013-04-23T08:44:08 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,910 | cpp | /*
By Nestori, 2013
don't blame me when stuff burns
I mean if
*/
#include "lowlvl.h"
#ifdef FORAERY
//data pins, db00 - db15 are portb 0 - 15 pins
//controlling pins
const uint8_t PIN_RS = AVR32_PIN_PA23;
const uint8_t PIN_WR = AVR32_PIN_PA24;
const uint8_t PIN_RD = AVR32_PIN_PA25;
const uint8_t PIN_CS = AVR32_PIN_PA26;
const uint8_t PIN_RESET = AVR32_PIN_PA27;
// low level
void lcd_com(uint8_t command)
{
//set cs, rs, and data pins low, hard-coding a value here does not incr performance.
AVR32_GPIO_LOCAL.port[1].ovrc = 0xFFFF;
AVR32_GPIO_LOCAL.port[0].ovrc = (1 << GPIO_NUM2PIN(PIN_CS)) | (1 << GPIO_NUM2PIN(PIN_RS));
//set data pins
AVR32_GPIO_LOCAL.port[1].ovrs = command;
//pulse wr pins, and set cs, rs back on
AVR32_GPIO_LOCAL.port[0].ovrc = (1 << GPIO_NUM2PIN(PIN_WR));
AVR32_GPIO_LOCAL.port[0].ovrs = (1 << GPIO_NUM2PIN(PIN_WR)) | (1 << GPIO_NUM2PIN(PIN_CS)) | (1 << GPIO_NUM2PIN(PIN_RS));
}
void lcd_data(uint16_t data)
{
AVR32_GPIO_LOCAL.port[1].ovrc = 0xFFFF;
AVR32_GPIO_LOCAL.port[0].ovrc = (1 << GPIO_NUM2PIN(PIN_CS));
AVR32_GPIO_LOCAL.port[1].ovrs = data;
AVR32_GPIO_LOCAL.port[0].ovrc = (1 << GPIO_NUM2PIN(PIN_WR));
AVR32_GPIO_LOCAL.port[0].ovrs = (1 << GPIO_NUM2PIN(PIN_WR)) | (1 << GPIO_NUM2PIN(PIN_CS));
}
void command_lcd(uint8_t command, uint16_t data)
{
lcd_com(command);
lcd_data(data);
}
#endif
//aery32 ends here
#ifdef FORPC
void lcd_com(uint8_t command)
{
//we dont need this to do anything on pc
}
void lcd_data(uint16_t data)
{
//i hope this does not need commenting, other than data == color
simscreen_setpixel(data);
}
void command_lcd(uint8_t command, uint16_t data)
{
//if we get command 0x4e, by ssd1289 documentation it means moving y pointer position in lcd's graphical ram
if (command == 0x4E)
{
simscreen_movey(data);
}
//moves x pointer position in lcd's graphical ram
if (command == 0x4F)
{
simscreen_movex(data);
}
}
#endif | [
"nestori@server.fake"
] | nestori@server.fake |
d60d724b743d78be9a4a172310e2f1333c58cd90 | 33b567f6828bbb06c22a6fdf903448bbe3b78a4f | /opencascade/BVH_Constants.hxx | db5e1707c696e850c96bd7de303280b0239e2136 | [
"Apache-2.0"
] | permissive | CadQuery/OCP | fbee9663df7ae2c948af66a650808079575112b5 | b5cb181491c9900a40de86368006c73f169c0340 | refs/heads/master | 2023-07-10T18:35:44.225848 | 2023-06-12T18:09:07 | 2023-06-12T18:09:07 | 228,692,262 | 64 | 28 | Apache-2.0 | 2023-09-11T12:40:09 | 2019-12-17T20:02:11 | C++ | UTF-8 | C++ | false | false | 1,852 | hxx | // Copyright (c) 2017 OPEN CASCADE SAS
//
// This file is part of Open CASCADE Technology software library.
//
// This library is free software; you can redistribute it and/or modify it under
// the terms of the GNU Lesser General Public License version 2.1 as published
// by the Free Software Foundation, with special exception defined in the file
// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
// distribution for complete text of the license and disclaimer of any warranty.
//
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
#ifndef _BVH_Constants_Header
#define _BVH_Constants_Header
enum
{
//! The optimal tree depth.
//! Should be in sync with maximum stack size while traversing the tree - don't pass the trees of greater depth to OCCT algorithms!
BVH_Constants_MaxTreeDepth = 32,
//! Leaf node size optimal for complex nodes,
//! e.g. for upper-level BVH trees within multi-level structure (nodes point to another BVH trees).
BVH_Constants_LeafNodeSizeSingle = 1,
//! Average leaf node size (4 primitive per leaf), optimal for average tree nodes.
BVH_Constants_LeafNodeSizeAverage = 4,
//! Default leaf node size (5 primitives per leaf).
BVH_Constants_LeafNodeSizeDefault = 5,
//! Leaf node size (8 primitives per leaf), optimal for small tree nodes (e.g. triangles).
BVH_Constants_LeafNodeSizeSmall = 8,
//! The optimal number of bins for binned builder.
BVH_Constants_NbBinsOptimal = 32,
//! The maximum number of bins for binned builder (giving the best traversal time at cost of longer tree construction time).
BVH_Constants_NbBinsBest = 48,
};
namespace BVH
{
//! Minimum node size to split.
const double THE_NODE_MIN_SIZE = 1e-5;
}
#endif // _BVH_Constants_Header
| [
"adam.jan.urbanczyk@gmail.com"
] | adam.jan.urbanczyk@gmail.com |
04b23c7e481059248ff08b275f9d07a1460c3c3b | 3292ecba93bd0c329e8a6d2eb5acb697bd11e507 | /All Codes/URI_2896.cpp | 2b2d941365aaec6edc9ad105aaf42272cae26714 | [
"MIT"
] | permissive | BrunaCorty/URI-Online-Judge-Solutions | 4e37b1082cfba566eb026460a3d49663b9b701cb | 62aa23f4bfcf9ea2a1054451c6380ed827816b3c | refs/heads/master | 2023-02-14T04:01:36.415001 | 2021-01-12T17:26:13 | 2021-01-12T17:26:13 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 357 | cpp | #include <iostream>
using namespace std;
int main() {
int t, k, n, temp;
cin >> t;
while (t--)
{
cin >> k >> n;
if (k > n) {
temp = (k / n) + (k % n);
} else if (k < n) {
temp = k;
} else {
temp = 1;
}
cout << temp << "\n";
}
return 0;
}
| [
"anuhimel@gmail.com"
] | anuhimel@gmail.com |
161d9c327a3b5e5e4af4f0605b9f0c43f38a2d36 | 4c2966241a4ee36120cbdf22a145c57f2387a2bd | /CvUnit.h | 112b8d82f62f3ce5a931c08d6ffd989aa9d8f743 | [] | no_license | Ninakoru/Civ-5-BNW-Smart-AI | 17cc273c625bdcffda262e2a9d0b116dfde65618 | 5ed09f668f339030c6b9fb80e0740100631e18ba | refs/heads/master | 2021-01-20T12:10:28.959507 | 2016-02-01T00:52:04 | 2016-02-01T00:52:04 | 49,821,819 | 2 | 0 | null | null | null | null | WINDOWS-1252 | C++ | false | false | 52,508 | h | /* -------------------------------------------------------------------------------------------------------
© 1991-2012 Take-Two Interactive Software and its subsidiaries. Developed by Firaxis Games.
Sid Meier's Civilization V, Civ, Civilization, 2K Games, Firaxis Games, Take-Two Interactive Software
and their respective logos are all trademarks of Take-Two interactive Software, Inc.
All other marks and trademarks are the property of their respective owners.
All rights reserved.
------------------------------------------------------------------------------------------------------- */
#pragma once
// unit.h
#ifndef CIV5_UNIT_H
#define CIV5_UNIT_H
#include "CvEnumSerialization.h"
#include "FStlContainerSerialization.h"
#include "FAutoVariable.h"
#include "FAutoVector.h"
#include "FObjectHandle.h"
#include "CvInfos.h"
#include "CvPromotionClasses.h"
#include "CvAStarNode.h"
#define DEFAULT_UNIT_MAP_LAYER 0
#pragma warning( disable: 4251 ) // needs to have dll-interface to be used by clients of class
class CvPlot;
class CvArea;
class CvAStarNode;
class CvArtInfoUnit;
class CvUnitEntry;
class CvUnitReligion;
class CvPathNode;
typedef MissionData MissionQueueNode;
typedef FFastSmallFixedList< MissionQueueNode, 12, true, c_eCiv5GameplayDLL > MissionQueue;
typedef FObjectHandle<CvUnit> UnitHandle;
typedef FStaticVector<CvPlot*, 20, true, c_eCiv5GameplayDLL, 0> UnitMovementQueue;
struct CvUnitCaptureDefinition
{
PlayerTypes eOriginalOwner; // Who first created the unit
PlayerTypes eOldPlayer; // The previous owner of the unit, no necessarily the original owner
UnitTypes eOldType; // Previous type of the unit, the type can change when capturing
PlayerTypes eCapturingPlayer;
UnitTypes eCaptureUnitType;
int iX;
int iY;
bool bEmbarked;
bool bAsIs;
ReligionTypes eReligion;
int iReligiousStrength;
int iSpreadsLeft;
CvUnitCaptureDefinition()
: eOriginalOwner(NO_PLAYER)
, eOldPlayer(NO_PLAYER)
, eOldType(NO_UNIT)
, eCapturingPlayer(NO_PLAYER)
, eCaptureUnitType(NO_UNIT)
, iX(-1)
, iY(-1)
, bEmbarked(false)
, bAsIs(false)
, eReligion(NO_RELIGION)
, iReligiousStrength(0)
, iSpreadsLeft(0) { }
inline bool IsValid() const
{
return eCapturingPlayer != NO_PLAYER && eCaptureUnitType != NO_UNIT;
}
};
class CvUnit
{
friend class CvUnitMission;
friend class CvUnitCombat;
public:
CvUnit();
~CvUnit();
enum
{
MOVEFLAG_ATTACK = 0x001,
MOVEFLAG_DECLARE_WAR = 0x002,
MOVEFLAG_DESTINATION = 0x004,
MOVEFLAG_NOT_ATTACKING_THIS_TURN = 0x008,
MOVEFLAG_IGNORE_STACKING = 0x010,
MOVEFLAG_PRETEND_EMBARKED = 0x020, // so we can check movement as if the unit was embarked
MOVEFLAG_PRETEND_UNEMBARKED = 0x040, // to check movement as if the unit was unembarked
MOVEFLAG_PRETEND_CORRECT_EMBARK_STATE = 0x080, // check to see if the unit can move into the tile in an embarked or unembarked state
MOVEFLAG_STAY_ON_LAND = 0x100, // don't embark, even if you can
};
DestructionNotification<UnitHandle>& getDestructionNotification();
void init(int iID, UnitTypes eUnit, UnitAITypes eUnitAI, PlayerTypes eOwner, int iX, int iY, DirectionTypes eFacingDirection, bool bNoMove, bool bSetupGraphical=true, int iMapLayer = DEFAULT_UNIT_MAP_LAYER, int iNumGoodyHutsPopped = 0);
void initWithNameOffset(int iID, UnitTypes eUnit, int iNameOffset, UnitAITypes eUnitAI, PlayerTypes eOwner, int iX, int iY, DirectionTypes eFacingDirection, bool bNoMove, bool bSetupGraphical=true, int iMapLayer = DEFAULT_UNIT_MAP_LAYER, int iNumGoodyHutsPopped = 0);
void uninit();
void reset(int iID = 0, UnitTypes eUnit = NO_UNIT, PlayerTypes eOwner = NO_PLAYER, bool bConstructorCall = false);
void setupGraphical();
void initPromotions();
void uninitInfos(); // used to uninit arrays that may be reset due to mod changes
void convert(CvUnit* pUnit, bool bIsUpgrade);
void kill(bool bDelay, PlayerTypes ePlayer = NO_PLAYER);
void doTurn();
bool isActionRecommended(int iAction);
bool isBetterDefenderThan(const CvUnit* pDefender, const CvUnit* pAttacker) const;
bool canDoCommand(CommandTypes eCommand, int iData1, int iData2, bool bTestVisible = false, bool bTestBusy = true) const;
void doCommand(CommandTypes eCommand, int iData1, int iData2);
bool IsDoingPartialMove() const;
ActivityTypes GetActivityType() const;
void SetActivityType(ActivityTypes eNewValue);
AutomateTypes GetAutomateType() const;
bool IsAutomated() const;
void SetAutomateType(AutomateTypes eNewValue);
bool CanAutomate(AutomateTypes eAutomate, bool bTestVisible = false) const;
void Automate(AutomateTypes eAutomate);
bool ReadyToSelect() const;
bool ReadyToMove() const;
bool ReadyToAuto() const;
bool IsBusy() const;
bool SentryAlert() const;
bool ShowMoves() const;
bool CanDoInterfaceMode(InterfaceModeTypes eInterfaceMode, bool bTestVisibility = false);
bool IsDeclareWar() const;
RouteTypes GetBestBuildRoute(CvPlot* pPlot, BuildTypes* peBestBuild = NULL) const;
void PlayActionSound();
bool UnitAttack(int iX, int iY, int iFlags, int iSteps=0);
bool UnitMove(CvPlot* pPlot, bool bCombat, CvUnit* pCombatUnit, bool bEndMove = false);
int UnitPathTo(int iX, int iY, int iFlags, int iPrevETA = -1, bool bBuildingRoute = false); // slewis'd the iPrevETA
bool UnitRoadTo(int iX, int iY, int iFlags);
bool UnitBuild(BuildTypes eBuild);
bool canEnterTerritory(TeamTypes eTeam, bool bIgnoreRightOfPassage = false, bool bIsCity = false, bool bIsDeclareWarMove = false) const;
bool canEnterTerrain(const CvPlot& pPlot, byte bMoveFlags = 0) const;
TeamTypes GetDeclareWarMove(const CvPlot& pPlot) const;
PlayerTypes GetBullyMinorMove(const CvPlot* pPlot) const;
TeamTypes GetDeclareWarRangeStrike(const CvPlot& pPlot) const;
bool canMoveInto(const CvPlot& pPlot, byte bMoveFlags = 0) const;
bool canMoveOrAttackInto(const CvPlot& pPlot, byte bMoveFlags = 0) const;
bool canMoveThrough(const CvPlot& pPlot, byte bMoveFlags = 0) const;
bool IsAngerFreeUnit() const;
int getCombatDamage(int iStrength, int iOpponentStrength, int iCurrentDamage, bool bIncludeRand, bool bAttackerIsCity, bool bDefenderIsCity) const;
void fightInterceptor(const CvPlot& pPlot);
void move(CvPlot& pPlot, bool bShow);
bool jumpToNearestValidPlot();
bool jumpToNearestValidPlotWithinRange(int iRange);
bool canScrap(bool bTestVisible = false) const;
void scrap();
int GetScrapGold() const;
bool canGift(bool bTestVisible = false, bool bTestTransport = true) const;
void gift(bool bTestTransport = true);
bool CanDistanceGift(PlayerTypes eToPlayer) const;
// Cargo/transport methods (units inside other units)
bool canLoadUnit(const CvUnit& pUnit, const CvPlot& pPlot) const;
void loadUnit(CvUnit& pUnit);
bool canLoad(const CvPlot& pPlot) const;
void load();
bool shouldLoadOnMove(const CvPlot* pPlot) const;
bool canUnload() const;
void unload();
bool canUnloadAll() const;
void unloadAll();
const CvUnit* getTransportUnit() const;
CvUnit* getTransportUnit();
bool isCargo() const;
void setTransportUnit(CvUnit* pTransportUnit);
SpecialUnitTypes specialCargo() const;
DomainTypes domainCargo() const;
int cargoSpace() const;
void changeCargoSpace(int iChange);
bool isFull() const;
int cargoSpaceAvailable(SpecialUnitTypes eSpecialCargo = NO_SPECIALUNIT, DomainTypes eDomainCargo = NO_DOMAIN) const;
bool hasCargo() const;
bool canCargoAllMove() const;
int getUnitAICargo(UnitAITypes eUnitAI) const;
//
bool canHold(const CvPlot* pPlot) const; // skip turn
bool canSleep(const CvPlot* pPlot) const;
bool canFortify(const CvPlot* pPlot) const;
bool canAirPatrol(const CvPlot* pPlot) const;
bool IsRangeAttackIgnoreLOS() const;
int GetRangeAttackIgnoreLOSCount() const;
void ChangeRangeAttackIgnoreLOSCount(int iChange);
bool canSetUpForRangedAttack(const CvPlot* pPlot) const;
bool isSetUpForRangedAttack() const;
void setSetUpForRangedAttack(bool bValue);
bool IsCityAttackOnly() const;
void ChangeCityAttackOnlyCount(int iChange);
bool IsCaptureDefeatedEnemy() const;
void ChangeCaptureDefeatedEnemyCount(int iChange);
int GetCaptureChance(CvUnit *pEnemy);
bool canEmbark(const CvPlot* pPlot) const;
bool canDisembark(const CvPlot* pPlot) const;
bool canEmbarkOnto(const CvPlot& pOriginPlot, const CvPlot& pTargetPlot, bool bOverrideEmbarkedCheck = false, bool bIsDestination = false) const;
bool canDisembarkOnto(const CvPlot& pOriginPlot, const CvPlot& pTargetPlot, bool bOverrideEmbarkedCheck = false, bool bIsDestination = false) const;
bool canDisembarkOnto(const CvPlot& pTargetPlot, bool bIsDestination = false) const;
bool CanEverEmbark() const; // can this unit ever change into an embarked unit
void embark(CvPlot* pPlot);
void disembark(CvPlot* pPlot);
inline bool isEmbarked() const
{
return m_bEmbarked;
}
void setEmbarked(bool bValue);
bool IsHasEmbarkAbility() const;
int GetEmbarkAbilityCount() const;
void ChangeEmbarkAbilityCount(int iChange);
bool canHeal(const CvPlot* pPlot, bool bTestVisible = false) const;
bool canSentry(const CvPlot* pPlot) const;
int healRate(const CvPlot* pPlot) const;
int healTurns(const CvPlot* pPlot) const;
void doHeal();
void DoAttrition();
bool canAirlift(const CvPlot* pPlot) const;
bool canAirliftAt(const CvPlot* pPlot, int iX, int iY) const;
bool airlift(int iX, int iY);
bool isNukeVictim(const CvPlot* pPlot, TeamTypes eTeam) const;
bool canNuke(const CvPlot* pPlot) const;
bool canNukeAt(const CvPlot* pPlot, int iX, int iY) const;
bool canParadrop(const CvPlot* pPlot, bool bOnlyTestVisibility) const;
bool canParadropAt(const CvPlot* pPlot, int iX, int iY) const;
bool paradrop(int iX, int iY);
bool canMakeTradeRoute(const CvPlot* pPlot) const;
bool canMakeTradeRouteAt(const CvPlot* pPlot, int iX, int iY, TradeConnectionType eConnectionType) const;
bool makeTradeRoute(int iX, int iY, TradeConnectionType eConnectionType);
bool canChangeTradeUnitHomeCity(const CvPlot* pPlot) const;
bool canChangeTradeUnitHomeCityAt(const CvPlot* pPlot, int iX, int iY) const;
bool changeTradeUnitHomeCity(int iX, int iY);
bool canChangeAdmiralPort(const CvPlot* pPlot) const;
bool canChangeAdmiralPortAt(const CvPlot* pPlot, int iX, int iY) const;
bool changeAdmiralPort(int iX, int iY);
bool canPlunderTradeRoute(const CvPlot* pPlot, bool bOnlyTestVisibility = false) const;
bool plunderTradeRoute();
bool canCreateGreatWork(const CvPlot* pPlot, bool bOnlyTestVisibility = false) const;
bool createGreatWork();
int getNumExoticGoods() const;
void setNumExoticGoods(int iValue);
void changeNumExoticGoods(int iChange);
float calculateExoticGoodsDistanceFactor(const CvPlot* pPlot);
bool canSellExoticGoods(const CvPlot* pPlot, bool bOnlyTestVisibility = false) const;
int getExoticGoodsGoldAmount();
int getExoticGoodsXPAmount();
bool sellExoticGoods();
bool canRebase(const CvPlot* pPlot) const;
bool canRebaseAt(const CvPlot* pPlot, int iX, int iY) const;
bool rebase(int iX, int iY);
bool canPillage(const CvPlot* pPlot) const;
bool pillage();
bool canFound(const CvPlot* pPlot, bool bTestVisible = false) const;
bool found();
bool canJoin(const CvPlot* pPlot, SpecialistTypes eSpecialist) const;
bool join(SpecialistTypes eSpecialist);
bool canConstruct(const CvPlot* pPlot, BuildingTypes eBuilding) const;
bool construct(BuildingTypes eBuilding);
bool CanFoundReligion(const CvPlot* pPlot) const;
bool DoFoundReligion();
bool CanEnhanceReligion(const CvPlot* pPlot) const;
bool DoEnhanceReligion();
bool CanSpreadReligion(const CvPlot* pPlot) const;
bool DoSpreadReligion();
bool CanRemoveHeresy(const CvPlot* pPlot) const;
bool DoRemoveHeresy();
int GetNumFollowersAfterSpread() const;
ReligionTypes GetMajorityReligionAfterSpread() const;
CvCity *GetSpreadReligionTargetCity() const;
int GetConversionStrength() const;
bool canDiscover(const CvPlot* pPlot, bool bTestVisible = false) const;
int getDiscoverAmount();
bool discover();
bool IsCanRushBuilding(CvCity* pCity, bool bTestVisible) const;
bool DoRushBuilding();
int getMaxHurryProduction(CvCity* pCity) const;
int getHurryProduction(const CvPlot* pPlot) const;
bool canHurry(const CvPlot* pPlot, bool bTestVisible = false) const;
bool hurry();
int getTradeGold(const CvPlot* pPlot) const;
int getTradeInfluence(const CvPlot* pPlot) const;
bool canTrade(const CvPlot* pPlot, bool bTestVisible = false) const;
bool trade();
bool canBuyCityState(const CvPlot* pPlot, bool bTestVisible = false) const;
bool buyCityState();
bool canRepairFleet(const CvPlot *pPlot, bool bTestVisible = false) const;
bool repairFleet();
bool CanBuildSpaceship(const CvPlot* pPlot, bool bTestVisible) const;
bool DoBuildSpaceship();
bool CanCultureBomb(const CvPlot* pPlot, bool bTestVisible = false) const;
bool DoCultureBomb();
void PerformCultureBomb(int iRadius);
bool canGoldenAge(const CvPlot* pPlot, bool bTestVisible = false) const;
bool goldenAge();
int GetGoldenAgeTurns() const;
bool canGivePolicies(const CvPlot* pPlot, bool bTestVisible = false) const;
int getGivePoliciesCulture();
bool givePolicies();
bool canBlastTourism(const CvPlot* pPlot, bool bTestVisible = false) const;
int getBlastTourism();
bool blastTourism();
bool canBuild(const CvPlot* pPlot, BuildTypes eBuild, bool bTestVisible = false, bool bTestGold = true) const;
bool build(BuildTypes eBuild);
bool canPromote(PromotionTypes ePromotion, int iLeaderUnitId) const;
void promote(PromotionTypes ePromotion, int iLeaderUnitId);
int canLead(const CvPlot* pPlot, int iUnitId) const;
bool lead(int iUnitId);
int canGiveExperience(const CvPlot* pPlot) const;
bool giveExperience();
int getStackExperienceToGive(int iNumUnits) const;
bool isReadyForUpgrade() const;
bool CanUpgradeRightNow(bool bOnlyTestVisible) const;
UnitTypes GetUpgradeUnitType() const;
int upgradePrice(UnitTypes eUnit) const;
CvUnit* DoUpgrade();
HandicapTypes getHandicapType() const;
CvCivilizationInfo& getCivilizationInfo() const;
CivilizationTypes getCivilizationType() const;
const char* getVisualCivAdjective(TeamTypes eForTeam) const;
SpecialUnitTypes getSpecialUnitType() const;
bool IsGreatPerson() const;
UnitTypes getCaptureUnitType(CivilizationTypes eCivilization) const;
UnitCombatTypes getUnitCombatType() const;
DomainTypes getDomainType() const;
int flavorValue(FlavorTypes eFlavor) const;
bool isBarbarian() const;
bool isHuman() const;
void DoTestBarbarianThreatToMinorsWithThisUnitsDeath(PlayerTypes eKillingPlayer);
bool IsBarbarianUnitThreateningMinor(PlayerTypes eMinor);
int visibilityRange() const;
bool canChangeVisibility() const;
int baseMoves(DomainTypes eIntoDomain = NO_DOMAIN) const;
int maxMoves() const;
int movesLeft() const;
bool canMove() const;
bool hasMoved() const;
int GetRange() const;
int GetNukeDamageLevel() const;
bool canBuildRoute() const;
BuildTypes getBuildType() const;
int workRate(bool bMax, BuildTypes eBuild = NO_BUILD) const;
bool isNoBadGoodies() const;
bool isRivalTerritory() const;
int getRivalTerritoryCount() const;
void changeRivalTerritoryCount(int iChange);
bool isFound() const;
bool IsFoundAbroad() const;
bool IsWork() const;
bool isGoldenAge() const;
bool isGivesPolicies() const;
bool isBlastTourism() const;
bool canCoexistWithEnemyUnit(TeamTypes eTeam) const;
bool isMustSetUpToRangedAttack() const;
int getMustSetUpToRangedAttackCount() const;
void changeMustSetUpToRangedAttackCount(int iChange);
bool isRangedSupportFire() const;
int getRangedSupportFireCount() const;
void changeRangedSupportFireCount(int iChange);
bool isFighting() const;
bool isAttacking() const;
bool isDefending() const;
bool isInCombat() const;
int GetMaxHitPoints() const;
int GetCurrHitPoints() const;
bool IsHurt() const;
bool IsDead() const;
int GetStrategicResourceCombatPenalty() const;
int GetUnhappinessCombatPenalty() const;
void SetBaseCombatStrength(int iCombat);
int GetBaseCombatStrength(bool bIgnoreEmbarked = false) const;
int GetBaseCombatStrengthConsideringDamage() const;
int GetGenericMaxStrengthModifier(const CvUnit* pOtherUnit, const CvPlot* pBattlePlot, bool bIgnoreUnitAdjacency) const;
int GetMaxAttackStrength(const CvPlot* pFromPlot, const CvPlot* pToPlot, const CvUnit* pDefender) const;
int GetMaxDefenseStrength(const CvPlot* pInPlot, const CvUnit* pAttacker, bool bFromRangedAttack = false) const;
int GetEmbarkedUnitDefense() const;
bool canSiege(TeamTypes eTeam) const;
int GetBaseRangedCombatStrength() const;
int GetMaxRangedCombatStrength(const CvUnit* pOtherUnit, const CvCity* pCity, bool bAttacking, bool bForRangedAttack) const;
int GetAirCombatDamage(const CvUnit* pDefender, CvCity* pCity, bool bIncludeRand, int iAssumeExtraDamage = 0) const;
int GetRangeCombatDamage(const CvUnit* pDefender, CvCity* pCity, bool bIncludeRand, int iAssumeExtraDamage = 0) const;
bool canAirAttack() const;
bool canAirDefend(const CvPlot* pPlot = NULL) const;
#if defined(MOD_AI_SMART_ENEMY_SCORE_AT_RANGE)
int EnemyScoreAtRange(const CvPlot* pPlot, bool onlyInterceptors) const;
#endif
int GetAirStrikeDefenseDamage(const CvUnit* pAttacker, bool bIncludeRand = true) const;
CvUnit* GetBestInterceptor(const CvPlot& pPlot, CvUnit* pkDefender = NULL, bool bLandInterceptorsOnly=false, bool bVisibleInterceptorsOnly=false) const;
int GetInterceptorCount(const CvPlot& pPlot, CvUnit* pkDefender = NULL, bool bLandInterceptorsOnly=false, bool bVisibleInterceptorsOnly=false) const;
int GetInterceptionDamage(const CvUnit* pAttacker, bool bIncludeRand = true) const;
int GetCombatLimit() const;
int GetRangedCombatLimit() const;
bool isWaiting() const;
bool isFortifyable(bool bCanWaitForNextTurn = false) const;
bool IsEverFortifyable() const;
int fortifyModifier() const;
int experienceNeeded() const;
int attackXPValue() const;
int defenseXPValue() const;
int maxXPValue() const;
int firstStrikes() const;
int chanceFirstStrikes() const;
int maxFirstStrikes() const;
bool isRanged() const;
bool immuneToFirstStrikes() const;
bool ignoreBuildingDefense() const;
bool ignoreTerrainCost() const;
int getIgnoreTerrainCostCount() const;
void changeIgnoreTerrainCostCount(int iValue);
bool IsRoughTerrainEndsTurn() const;
int GetRoughTerrainEndsTurnCount() const;
void ChangeRoughTerrainEndsTurnCount(int iValue);
bool IsHoveringUnit() const;
int GetHoveringUnitCount() const;
void ChangeHoveringUnitCount(int iValue);
bool flatMovementCost() const;
int getFlatMovementCostCount() const;
void changeFlatMovementCostCount(int iValue);
bool canMoveImpassable() const;
int getCanMoveImpassableCount() const;
void changeCanMoveImpassableCount(int iValue);
bool canMoveAllTerrain() const;
void changeCanMoveAllTerrainCount(int iValue);
int getCanMoveAllTerrainCount() const;
bool canMoveAfterAttacking() const;
void changeCanMoveAfterAttackingCount(int iValue);
int getCanMoveAfterAttackingCount() const;
bool hasFreePillageMove() const;
void changeFreePillageMoveCount(int iValue);
int getFreePillageMoveCount() const;
bool hasHealOnPillage() const;
void changeHealOnPillageCount(int iValue);
int getHealOnPillageCount() const;
bool isHiddenNationality() const;
void changeHiddenNationalityCount(int iValue);
int getHiddenNationalityCount() const;
bool isNoRevealMap() const;
void changeNoRevealMapCount(int iValue);
int getNoRevealMapCount() const;
bool isOnlyDefensive() const;
int getOnlyDefensiveCount() const;
void changeOnlyDefensiveCount(int iValue);
bool noDefensiveBonus() const;
int getNoDefensiveBonusCount() const;
void changeNoDefensiveBonusCount(int iValue);
bool isNoCapture() const;
int getNoCaptureCount() const;
void changeNoCaptureCount(int iValue);
bool isNeverInvisible() const;
bool isInvisible(TeamTypes eTeam, bool bDebug, bool bCheckCargo = true) const;
bool isNukeImmune() const;
void changeNukeImmuneCount(int iValue);
int getNukeImmuneCount() const;
int maxInterceptionProbability() const;
int currInterceptionProbability() const;
int evasionProbability() const;
int withdrawalProbability() const;
int GetNumEnemyUnitsAdjacent(const CvUnit* pUnitToExclude = NULL) const;
bool IsEnemyCityAdjacent() const;
bool IsEnemyCityAdjacent(const CvCity* pSpecifyCity) const;
int GetNumSpecificEnemyUnitsAdjacent(const CvUnit* pUnitToExclude = NULL, const CvUnit* pUnitCompare = NULL) const;
bool IsFriendlyUnitAdjacent(bool bCombatUnit) const;
int GetAdjacentModifier() const;
void ChangeAdjacentModifier(int iValue);
int GetRangedAttackModifier() const;
void ChangeRangedAttackModifier(int iValue);
int GetInterceptionCombatModifier() const;
void ChangeInterceptionCombatModifier(int iValue);
int GetInterceptionDefenseDamageModifier() const;
void ChangeInterceptionDefenseDamageModifier(int iValue);
int GetAirSweepCombatModifier() const;
void ChangeAirSweepCombatModifier(int iValue);
int getAttackModifier() const;
void changeAttackModifier(int iValue);
int getDefenseModifier() const;
void changeDefenseModifier(int iValue);
int cityAttackModifier() const;
int cityDefenseModifier() const;
int rangedDefenseModifier() const;
int hillsAttackModifier() const;
int hillsDefenseModifier() const;
int openAttackModifier() const;
int openRangedAttackModifier() const;
int roughAttackModifier() const;
int roughRangedAttackModifier() const;
int attackFortifiedModifier() const;
int attackWoundedModifier() const;
int openDefenseModifier() const;
int roughDefenseModifier() const;
int terrainAttackModifier(TerrainTypes eTerrain) const;
int terrainDefenseModifier(TerrainTypes eTerrain) const;
int featureAttackModifier(FeatureTypes eFeature) const;
int featureDefenseModifier(FeatureTypes eFeature) const;
int unitClassAttackModifier(UnitClassTypes eUnitClass) const;
int unitClassDefenseModifier(UnitClassTypes eUnitClass) const;
int unitCombatModifier(UnitCombatTypes eUnitCombat) const;
int domainModifier(DomainTypes eDomain) const;
bool IsHasNoValidMove() const;
inline int GetID() const
{
return m_iID;
}
int getIndex() const;
IDInfo GetIDInfo() const;
void SetID(int iID);
int getHotKeyNumber();
void setHotKeyNumber(int iNewValue);
inline int getX() const
{
return m_iX.get();
}
inline int getY() const
{
return m_iY.get();
}
void setXY(int iX, int iY, bool bGroup = false, bool bUpdate = true, bool bShow = false, bool bCheckPlotVisible = false, bool bNoMove = false);
bool at(int iX, int iY) const;
bool atPlot(const CvPlot& plot) const;
CvPlot* plot() const;
int getArea() const;
CvArea* area() const;
bool onMap() const;
int getLastMoveTurn() const;
void setLastMoveTurn(int iNewValue);
int GetCycleOrder() const;
void SetCycleOrder(int iNewValue);
int GetDeployFromOperationTurn() const
{
return m_iDeployFromOperationTurn;
};
void SetDeployFromOperationTurn(int iTurn)
{
m_iDeployFromOperationTurn = iTurn;
};
bool IsRecon() const;
int GetReconCount() const;
void ChangeReconCount(int iChange);
CvPlot* getReconPlot() const;
void setReconPlot(CvPlot* pNewValue);
int getGameTurnCreated() const;
void setGameTurnCreated(int iNewValue);
int getDamage() const;
int setDamage(int iNewValue, PlayerTypes ePlayer = NO_PLAYER, float fAdditionalTextDelay = 0.0f, const CvString* pAppendText = NULL);
int changeDamage(int iChange, PlayerTypes ePlayer = NO_PLAYER, float fAdditionalTextDelay = 0.0f, const CvString* pAppendText = NULL);
static void ShowDamageDeltaText(int iDelta, CvPlot* pkPlot, float fAdditionalTextDelay = 0.0f, const CvString* pAppendText = NULL);
int getMoves() const;
void setMoves(int iNewValue);
void changeMoves(int iChange);
void finishMoves();
bool IsImmobile() const;
void SetImmobile(bool bValue);
bool IsInFriendlyTerritory() const;
bool IsUnderEnemyRangedAttack() const;
int getExperience() const;
void setExperience(int iNewValue, int iMax = -1);
void changeExperience(int iChange, int iMax = -1, bool bFromCombat = false, bool bInBorders = false, bool bUpdateGlobal = false);
int getLevel() const;
void setLevel(int iNewValue);
void changeLevel(int iChange);
int getCargo() const;
void changeCargo(int iChange);
CvPlot* getAttackPlot() const;
void setAttackPlot(const CvPlot* pNewValue, bool bAirCombat);
bool isAirCombat() const;
int getCombatTimer() const;
void setCombatTimer(int iNewValue);
void changeCombatTimer(int iChange);
int getCombatFirstStrikes() const;
void setCombatFirstStrikes(int iNewValue);
void changeCombatFirstStrikes(int iChange);
bool IsGarrisoned(void) const;
CvCity* GetGarrisonedCity();
int getFortifyTurns() const;
void setFortifyTurns(int iNewValue);
void changeFortifyTurns(int iChange);
bool IsFortifiedThisTurn() const;
void SetFortifiedThisTurn(bool bValue);
int getBlitzCount() const;
bool isBlitz() const;
void changeBlitzCount(int iChange);
int getAmphibCount() const;
bool isAmphib() const;
void changeAmphibCount(int iChange);
int getRiverCrossingNoPenaltyCount() const;
bool isRiverCrossingNoPenalty() const;
void changeRiverCrossingNoPenaltyCount(int iChange);
int getEnemyRouteCount() const;
bool isEnemyRoute() const;
void changeEnemyRouteCount(int iChange);
int getAlwaysHealCount() const;
bool isAlwaysHeal() const;
void changeAlwaysHealCount(int iChange);
int getHealOutsideFriendlyCount() const;
bool isHealOutsideFriendly() const;
void changeHealOutsideFriendlyCount(int iChange);
int getHillsDoubleMoveCount() const;
bool isHillsDoubleMove() const;
void changeHillsDoubleMoveCount(int iChange);
int getImmuneToFirstStrikesCount() const;
void changeImmuneToFirstStrikesCount(int iChange);
int getExtraVisibilityRange() const;
void changeExtraVisibilityRange(int iChange);
int getExtraMoves() const;
void changeExtraMoves(int iChange);
int getExtraMoveDiscount() const;
void changeExtraMoveDiscount(int iChange);
int getExtraNavalMoves() const;
void changeExtraNavalMoves(int iChange);
int getHPHealedIfDefeatEnemy() const;
void changeHPHealedIfDefeatEnemy(int iValue);
bool IsHealIfDefeatExcludeBarbarians() const;
int GetHealIfDefeatExcludeBarbariansCount() const;
void ChangeHealIfDefeatExcludeBarbariansCount(int iValue);
int GetGoldenAgeValueFromKills() const;
void ChangeGoldenAgeValueFromKills(int iValue);
int getExtraRange() const;
void changeExtraRange(int iChange);
int getExtraIntercept() const;
void changeExtraIntercept(int iChange);
int getExtraEvasion() const;
void changeExtraEvasion(int iChange);
int getExtraFirstStrikes() const;
void changeExtraFirstStrikes(int iChange);
int getExtraChanceFirstStrikes() const;
void changeExtraChanceFirstStrikes(int iChange);
int getExtraWithdrawal() const;
void changeExtraWithdrawal(int iChange);
int getExtraEnemyHeal() const;
void changeExtraEnemyHeal(int iChange);
int getExtraNeutralHeal() const;
void changeExtraNeutralHeal(int iChange);
int getExtraFriendlyHeal() const;
void changeExtraFriendlyHeal(int iChange);
int getSameTileHeal() const;
void changeSameTileHeal(int iChange);
int getAdjacentTileHeal() const;
void changeAdjacentTileHeal(int iChange);
int getEnemyDamageChance() const;
void changeEnemyDamageChance(int iChange);
int getNeutralDamageChance() const;
void changeNeutralDamageChance(int iChange);
int getEnemyDamage() const;
void changeEnemyDamage(int iChange);
int getNeutralDamage() const;
void changeNeutralDamage(int iChange);
int getNearbyEnemyCombatMod() const;
void changeNearbyEnemyCombatMod(int iChange);
int getNearbyEnemyCombatRange() const;
void changeNearbyEnemyCombatRange(int iChange);
int getExtraCombatPercent() const;
void changeExtraCombatPercent(int iChange);
int getExtraCityAttackPercent() const;
void changeExtraCityAttackPercent(int iChange);
int getExtraCityDefensePercent() const;
void changeExtraCityDefensePercent(int iChange);
int getExtraRangedDefenseModifier() const;
void changeExtraRangedDefenseModifier(int iChange);
int getExtraHillsAttackPercent() const;
void changeExtraHillsAttackPercent(int iChange);
int getExtraHillsDefensePercent() const;
void changeExtraHillsDefensePercent(int iChange);
int getExtraOpenAttackPercent() const;
void changeExtraOpenAttackPercent(int iChange);
int getExtraOpenRangedAttackMod() const;
void changeExtraOpenRangedAttackMod(int iChange);
int getExtraRoughAttackPercent() const;
void changeExtraRoughAttackPercent(int iChange);
int getExtraRoughRangedAttackMod() const;
void changeExtraRoughRangedAttackMod(int iChange);
int getExtraAttackFortifiedMod() const;
void changeExtraAttackFortifiedMod(int iChange);
int getExtraAttackWoundedMod() const;
void changeExtraAttackWoundedMod(int iChange);
int GetFlankAttackModifier() const;
void ChangeFlankAttackModifier(int iChange);
int getExtraOpenDefensePercent() const;
void changeExtraOpenDefensePercent(int iChange);
int getExtraRoughDefensePercent() const;
void changeExtraRoughDefensePercent(int iChange);
void changeExtraAttacks(int iChange);
// Citadel
bool IsNearEnemyCitadel(int& iCitadelDamage);
// Great General Stuff
bool IsNearGreatGeneral() const;
bool IsStackedGreatGeneral() const;
int GetGreatGeneralStackMovement() const;
int GetReverseGreatGeneralModifier() const;
int GetNearbyImprovementModifier() const;
bool IsGreatGeneral() const;
int GetGreatGeneralCount() const;
void ChangeGreatGeneralCount(int iChange);
bool IsGreatAdmiral() const;
int GetGreatAdmiralCount() const;
void ChangeGreatAdmiralCount(int iChange);
int getGreatGeneralModifier() const;
void changeGreatGeneralModifier(int iChange);
bool IsGreatGeneralReceivesMovement() const;
void ChangeGreatGeneralReceivesMovementCount(int iChange);
int GetGreatGeneralCombatModifier() const;
void ChangeGreatGeneralCombatModifier(int iChange);
bool IsIgnoreGreatGeneralBenefit() const;
void ChangeIgnoreGreatGeneralBenefitCount(int iChange);
// END Great General Stuff
bool IsIgnoreZOC() const;
void ChangeIgnoreZOCCount(int iChange);
bool IsSapper() const;
void ChangeSapperCount(int iChange);
bool IsSappingCity(const CvCity* pTargetCity) const;
bool IsNearSapper(const CvCity* pTargetCity) const;
bool IsCanHeavyCharge() const;
void ChangeCanHeavyChargeCount(int iChange);
int getFriendlyLandsModifier() const;
void changeFriendlyLandsModifier(int iChange);
int getFriendlyLandsAttackModifier() const;
void changeFriendlyLandsAttackModifier(int iChange);
int getOutsideFriendlyLandsModifier() const;
void changeOutsideFriendlyLandsModifier(int iChange);
int getPillageChange() const;
void changePillageChange(int iChange);
int getUpgradeDiscount() const;
void changeUpgradeDiscount(int iChange);
int getExperiencePercent() const;
void changeExperiencePercent(int iChange);
int getKamikazePercent() const;
void changeKamikazePercent(int iChange);
DirectionTypes getFacingDirection(bool checkLineOfSightProperty) const;
void setFacingDirection(DirectionTypes facingDirection);
void rotateFacingDirectionClockwise();
void rotateFacingDirectionCounterClockwise();
bool isSuicide() const;
bool isTrade() const;
int getDropRange() const;
void changeDropRange(int iChange);
bool isOutOfAttacks() const;
void setMadeAttack(bool bNewValue);
int GetNumInterceptions() const;
void ChangeNumInterceptions(int iChange);
bool isOutOfInterceptions() const;
int getMadeInterceptionCount() const;
void setMadeInterception(bool bNewValue);
bool TurnProcessed() const;
void SetTurnProcessed(bool bValue);
bool isPromotionReady() const;
void setPromotionReady(bool bNewValue);
void testPromotionReady();
bool isDelayedDeath() const;
bool isDelayedDeathExported() const;
void startDelayedDeath();
bool doDelayedDeath();
bool isCombatFocus() const;
bool isInfoBarDirty() const;
void setInfoBarDirty(bool bNewValue);
bool IsNotConverting() const;
void SetNotConverting(bool bNewValue);
inline PlayerTypes getOwner() const
{
return m_eOwner.get();
}
PlayerTypes getVisualOwner(TeamTypes eForTeam = NO_TEAM) const;
PlayerTypes getCombatOwner(TeamTypes eForTeam, const CvPlot& pPlot) const;
TeamTypes getTeam() const;
PlayerTypes GetOriginalOwner() const;
void SetOriginalOwner(PlayerTypes ePlayer);
PlayerTypes getCapturingPlayer() const;
void setCapturingPlayer(PlayerTypes eNewValue);
bool IsCapturedAsIs() const;
void SetCapturedAsIs(bool bSetValue);
const UnitTypes getUnitType() const;
CvUnitEntry& getUnitInfo() const;
UnitClassTypes getUnitClassType() const;
const UnitTypes getLeaderUnitType() const;
void setLeaderUnitType(UnitTypes leaderUnitType);
const InvisibleTypes getInvisibleType() const;
void setInvisibleType(InvisibleTypes InvisibleType);
const InvisibleTypes getSeeInvisibleType() const;
void setSeeInvisibleType(InvisibleTypes InvisibleType);
const CvUnit* getCombatUnit() const;
CvUnit* getCombatUnit();
void setCombatUnit(CvUnit* pUnit, bool bAttacking = false);
const CvCity* getCombatCity() const;
CvCity* getCombatCity();
void setCombatCity(CvCity* pCity);
void clearCombat();
int getExtraDomainModifier(DomainTypes eIndex) const;
void changeExtraDomainModifier(DomainTypes eIndex, int iChange);
const CvString getName() const;
const char* getNameKey() const;
const CvString getNameNoDesc() const;
void setName(const CvString strNewValue);
GreatWorkType GetGreatWork() const;
void SetGreatWork(GreatWorkType eGreatWork);
int GetTourismBlastStrength() const;
void SetTourismBlastStrength(int iValue);
// Arbitrary Script Data
std::string getScriptData() const;
void setScriptData(std::string szNewValue);
int getScenarioData() const;
void setScenarioData(int iNewValue);
int getTerrainDoubleMoveCount(TerrainTypes eIndex) const;
bool isTerrainDoubleMove(TerrainTypes eIndex) const;
void changeTerrainDoubleMoveCount(TerrainTypes eIndex, int iChange);
int getFeatureDoubleMoveCount(FeatureTypes eIndex) const;
bool isFeatureDoubleMove(FeatureTypes eIndex) const;
void changeFeatureDoubleMoveCount(FeatureTypes eIndex, int iChange);
int getImpassableCount() const;
int getTerrainImpassableCount(TerrainTypes eIndex) const;
void changeTerrainImpassableCount(TerrainTypes eIndex, int iChange);
int getFeatureImpassableCount(FeatureTypes eIndex) const;
void changeFeatureImpassableCount(FeatureTypes eIndex, int iChange);
bool isTerrainImpassable(TerrainTypes eIndex) const
{
return m_terrainImpassableCount[eIndex] > 0;
}
bool isFeatureImpassable(FeatureTypes eIndex) const
{
return m_featureImpassableCount[eIndex] > 0;
}
int getExtraTerrainAttackPercent(TerrainTypes eIndex) const;
void changeExtraTerrainAttackPercent(TerrainTypes eIndex, int iChange);
int getExtraTerrainDefensePercent(TerrainTypes eIndex) const;
void changeExtraTerrainDefensePercent(TerrainTypes eIndex, int iChange);
int getExtraFeatureAttackPercent(FeatureTypes eIndex) const;
void changeExtraFeatureAttackPercent(FeatureTypes eIndex, int iChange);
int getExtraFeatureDefensePercent(FeatureTypes eIndex) const;
void changeExtraFeatureDefensePercent(FeatureTypes eIndex, int iChange);
int getExtraUnitCombatModifier(UnitCombatTypes eIndex) const;
void changeExtraUnitCombatModifier(UnitCombatTypes eIndex, int iChange);
int getUnitClassModifier(UnitClassTypes eIndex) const;
void changeUnitClassModifier(UnitClassTypes eIndex, int iChange);
bool canAcquirePromotion(PromotionTypes ePromotion) const;
bool canAcquirePromotionAny() const;
bool isPromotionValid(PromotionTypes ePromotion) const;
bool isHasPromotion(PromotionTypes eIndex) const;
void setHasPromotion(PromotionTypes eIndex, bool bNewValue);
int getSubUnitCount() const;
int getSubUnitsAlive() const;
int getSubUnitsAlive(int iDamage) const;
bool isEnemy(TeamTypes eTeam, const CvPlot* pPlot = NULL) const;
bool isPotentialEnemy(TeamTypes eTeam, const CvPlot* pPlot = NULL) const;
bool canRangeStrike() const;
#if defined(MOD_AI_SMART_RANGE_PLUS_MOVE_TO_SHOT)
int GetRangePlusMoveToshot() const;
#endif
#if defined(MOD_AI_SMART_CAN_EVER_RANGE_STRIKE_AT)
bool canEverRangeStrikeAt(int iX, int iY, const CvPlot* pSourcePlot = NULL) const;
#else
bool canEverRangeStrikeAt(int iX, int iY) const;
#endif
#if defined(MOD_AI_GET_MOVABLE_PLOT_LIST)
void GetMovablePlotListOpt(vector<CvPlot*>& plotData, CvPlot* plotTarget, bool exitOnFound, bool bIgnoreFriendlyUnits = false);
#endif
bool canRangeStrikeAt(int iX, int iY, bool bNeedWar = true, bool bNoncombatAllowed = true) const;
bool IsAirSweepCapable() const;
int GetAirSweepCapableCount() const;
void ChangeAirSweepCapableCount(int iChange);
bool canAirSweep() const;
bool canAirSweepAt(int iX, int iY) const;
bool airSweep(int iX, int iY);
bool potentialWarAction(const CvPlot* pPlot) const;
bool willRevealByMove(const CvPlot& pPlot) const;
bool isAlwaysHostile(const CvPlot& pPlot) const;
void changeAlwaysHostileCount(int iValue);
int getAlwaysHostileCount() const;
int getArmyID() const;
void setArmyID(int iNewArmyID) ;
bool isUnderTacticalControl() const;
void setTacticalMove(TacticalAIMoveTypes eMove);
TacticalAIMoveTypes getTacticalMove() const;
bool canRecruitFromTacticalAI() const;
void SetTacticalAIPlot(CvPlot* pPlot);
CvPlot* GetTacticalAIPlot() const;
void LogWorkerEvent(BuildTypes eBuildType, bool bStartingConstruction);
int GetPower() const;
bool AreUnitsOfSameType(const CvUnit& pUnit2, const bool bPretendEmbarked = false) const;
bool CanSwapWithUnitHere(CvPlot& pPlot) const;
void read(FDataStream& kStream);
void write(FDataStream& kStream) const;
void AI_promote();
UnitAITypes AI_getUnitAIType() const;
void AI_setUnitAIType(UnitAITypes eNewValue);
#if defined(MOD_AI_SMART_PROMOTION_VALUE)
int GetPromotionValue(int promotionBonus, int unitExtraValue, int matchFlavorValue, int baseValue);
#endif
int AI_promotionValue(PromotionTypes ePromotion);
GreatPeopleDirectiveTypes GetGreatPeopleDirective() const;
void SetGreatPeopleDirective(GreatPeopleDirectiveTypes eDirective);
bool IsSelected() const;
bool IsFirstTimeSelected() const;
void IncrementFirstTimeSelected();
void SetPosition(CvPlot* pkPlot);
const FAutoArchive& getSyncArchive() const;
FAutoArchive& getSyncArchive();
// Mission routines
void PushMission(MissionTypes eMission, int iData1 = -1, int iData2 = -1, int iFlags = 0, bool bAppend = false, bool bManual = false, MissionAITypes eMissionAI = NO_MISSIONAI, CvPlot* pMissionAIPlot = NULL, CvUnit* pMissionAIUnit = NULL);
void PopMission();
void AutoMission();
void UpdateMission();
CvPlot* LastMissionPlot();
bool CanStartMission(int iMission, int iData1, int iData2, CvPlot* pPlot = NULL, bool bTestVisible = false);
int GetMissionTimer() const;
void SetMissionTimer(int iNewValue);
void ChangeMissionTimer(int iChange);
void ClearMissionQueue(int iUnitCycleTimer = 1);
int GetLengthMissionQueue() const;
const MissionData* GetHeadMissionData();
const MissionData* GetMissionData(int iIndex);
CvPlot* GetMissionAIPlot();
MissionAITypes GetMissionAIType();
void SetMissionAI(MissionAITypes eNewMissionAI, CvPlot* pNewPlot, CvUnit* pNewUnit);
CvUnit* GetMissionAIUnit();
// Combat eligibility routines
inline bool IsCombatUnit() const
{
return (m_iBaseCombat > 0);
}
bool IsCanAttackWithMove() const;
bool IsCanAttackRanged() const;
bool IsCanAttack() const;
bool IsCanAttackWithMoveNow() const;
bool IsCanDefend(const CvPlot* pPlot = NULL) const;
bool IsEnemyInMovementRange(bool bOnlyFortified = false, bool bOnlyCities = false);
// Path-finding routines
bool GeneratePath(const CvPlot* pToPlot, int iFlags = 0, bool bReuse = false, int* piPathTurns = NULL) const;
void ResetPath();
CvPlot* GetPathFirstPlot() const;
CvPlot* GetPathLastPlot() const;
const CvPathNodeArray& GetPathNodeArray() const;
CvPlot* GetPathEndTurnPlot() const;
bool isBusyMoving() const;
void setBusyMoving(bool bState);
bool IsIgnoringDangerWakeup() const;
void SetIgnoreDangerWakeup(bool bState);
bool IsNotCivilianIfEmbarked() const;
void ChangeNotCivilianIfEmbarkedCount(int iValue);
int GetNotCivilianIfEmbarkedCount() const;
bool IsEmbarkAllWater() const;
void ChangeEmbarkAllWaterCount(int iValue);
int GetEmbarkAllWaterCount() const;
void ChangeEmbarkExtraVisibility(int iValue);
int GetEmbarkExtraVisibility() const;
void ChangeEmbarkDefensiveModifier(int iValue);
int GetEmbarkDefensiveModifier() const;
void ChangeCapitalDefenseModifier(int iValue);
int GetCapitalDefenseModifier() const;
void ChangeCapitalDefenseFalloff(int iValue);
int GetCapitalDefenseFalloff() const;
void ChangeCityAttackPlunderModifier(int iValue);
int GetCityAttackPlunderModifier() const;
void ChangeReligiousStrengthLossRivalTerritory(int iValue);
int GetReligiousStrengthLossRivalTerritory() const;
void ChangeTradeMissionInfluenceModifier(int iValue);
int GetTradeMissionInfluenceModifier() const;
void ChangeTradeMissionGoldModifier(int iValue);
int GetTradeMissionGoldModifier() const;
bool IsHasBeenPromotedFromGoody() const;
void SetBeenPromotedFromGoody(bool bBeenPromoted);
bool IsHigherTechThan(UnitTypes otherUnit) const;
bool IsLargerCivThan(const CvUnit* pOtherUnit) const;
int GetNumGoodyHutsPopped() const;
void ChangeNumGoodyHutsPopped(int iValue);
// Ported in from old CvUnitAI class
int SearchRange(int iRange) const;
bool PlotValid(CvPlot* pPlot) const;
CvUnitReligion* GetReligionData() const
{
return m_pReligion;
};
static void dispatchingNetMessage(bool dispatching);
static bool dispatchingNetMessage();
std::string debugDump(const FAutoVariableBase&) const;
std::string stackTraceRemark(const FAutoVariableBase&) const;
protected:
const MissionQueueNode* HeadMissionQueueNode() const;
MissionQueueNode* HeadMissionQueueNode();
bool getCaptureDefinition(CvUnitCaptureDefinition* pkCaptureDef, PlayerTypes eCapturingPlayer = NO_PLAYER);
static CvUnit* createCaptureUnit(const CvUnitCaptureDefinition& kCaptureDef);
void ClearPathCache();
bool UpdatePathCache(CvPlot* pDestPlot, int iFlags);
void QueueMoveForVisualization(CvPlot* pkPlot);
void PublishQueuedVisualizationMoves();
typedef enum Flags
{
UNITFLAG_EVALUATING_MISSION = 0x1,
UNITFLAG_ALREADY_GOT_GOODY_UPGRADE = 0x2
};
FAutoArchiveClassContainer<CvUnit> m_syncArchive;
FAutoVariable<PlayerTypes, CvUnit> m_eOwner;
FAutoVariable<PlayerTypes, CvUnit> m_eOriginalOwner;
FAutoVariable<UnitTypes, CvUnit> m_eUnitType;
FAutoVariable<int, CvUnit> m_iX;
FAutoVariable<int, CvUnit> m_iY;
FAutoVariable<int, CvUnit> m_iID;
FAutoVariable<int, CvUnit> m_iHotKeyNumber;
FAutoVariable<int, CvUnit> m_iDeployFromOperationTurn;
int m_iLastMoveTurn;
short m_iCycleOrder;
FAutoVariable<int, CvUnit> m_iReconX;
FAutoVariable<int, CvUnit> m_iReconY;
FAutoVariable<int, CvUnit> m_iReconCount;
FAutoVariable<int, CvUnit> m_iGameTurnCreated;
FAutoVariable<int, CvUnit> m_iDamage;
FAutoVariable<int, CvUnit> m_iMoves;
FAutoVariable<bool, CvUnit> m_bImmobile;
FAutoVariable<int, CvUnit> m_iExperience;
FAutoVariable<int, CvUnit> m_iLevel;
FAutoVariable<int, CvUnit> m_iCargo;
FAutoVariable<int, CvUnit> m_iCargoCapacity;
FAutoVariable<int, CvUnit> m_iAttackPlotX;
FAutoVariable<int, CvUnit> m_iAttackPlotY;
FAutoVariable<int, CvUnit> m_iCombatTimer;
FAutoVariable<int, CvUnit> m_iCombatFirstStrikes;
FAutoVariable<int, CvUnit> m_iCombatDamage;
FAutoVariable<int, CvUnit> m_iFortifyTurns;
FAutoVariable<bool, CvUnit> m_bFortifiedThisTurn;
FAutoVariable<int, CvUnit> m_iBlitzCount;
FAutoVariable<int, CvUnit> m_iAmphibCount;
FAutoVariable<int, CvUnit> m_iRiverCrossingNoPenaltyCount;
FAutoVariable<int, CvUnit> m_iEnemyRouteCount;
FAutoVariable<int, CvUnit> m_iRivalTerritoryCount;
FAutoVariable<int, CvUnit> m_iMustSetUpToRangedAttackCount;
FAutoVariable<int, CvUnit> m_iRangeAttackIgnoreLOSCount;
int m_iCityAttackOnlyCount;
int m_iCaptureDefeatedEnemyCount;
FAutoVariable<int, CvUnit> m_iRangedSupportFireCount;
FAutoVariable<int, CvUnit> m_iAlwaysHealCount;
FAutoVariable<int, CvUnit> m_iHealOutsideFriendlyCount;
FAutoVariable<int, CvUnit> m_iHillsDoubleMoveCount;
FAutoVariable<int, CvUnit> m_iImmuneToFirstStrikesCount;
FAutoVariable<int, CvUnit> m_iExtraVisibilityRange;
FAutoVariable<int, CvUnit> m_iExtraMoves;
FAutoVariable<int, CvUnit> m_iExtraMoveDiscount;
FAutoVariable<int, CvUnit> m_iExtraRange;
FAutoVariable<int, CvUnit> m_iExtraIntercept;
FAutoVariable<int, CvUnit> m_iExtraEvasion;
FAutoVariable<int, CvUnit> m_iExtraFirstStrikes;
FAutoVariable<int, CvUnit> m_iExtraChanceFirstStrikes;
FAutoVariable<int, CvUnit> m_iExtraWithdrawal;
FAutoVariable<int, CvUnit> m_iExtraEnemyHeal;
FAutoVariable<int, CvUnit> m_iExtraNeutralHeal;
FAutoVariable<int, CvUnit> m_iExtraFriendlyHeal;
int m_iEnemyDamageChance;
int m_iNeutralDamageChance;
int m_iEnemyDamage;
int m_iNeutralDamage;
int m_iNearbyEnemyCombatMod;
int m_iNearbyEnemyCombatRange;
FAutoVariable<int, CvUnit> m_iSameTileHeal;
FAutoVariable<int, CvUnit> m_iAdjacentTileHeal;
FAutoVariable<int, CvUnit> m_iAdjacentModifier;
FAutoVariable<int, CvUnit> m_iRangedAttackModifier;
FAutoVariable<int, CvUnit> m_iInterceptionCombatModifier;
FAutoVariable<int, CvUnit> m_iInterceptionDefenseDamageModifier;
FAutoVariable<int, CvUnit> m_iAirSweepCombatModifier;
FAutoVariable<int, CvUnit> m_iAttackModifier;
FAutoVariable<int, CvUnit> m_iDefenseModifier;
FAutoVariable<int, CvUnit> m_iExtraCombatPercent;
FAutoVariable<int, CvUnit> m_iExtraCityAttackPercent;
FAutoVariable<int, CvUnit> m_iExtraCityDefensePercent;
FAutoVariable<int, CvUnit> m_iExtraRangedDefenseModifier;
FAutoVariable<int, CvUnit> m_iExtraHillsAttackPercent;
FAutoVariable<int, CvUnit> m_iExtraHillsDefensePercent;
FAutoVariable<int, CvUnit> m_iExtraOpenAttackPercent;
FAutoVariable<int, CvUnit> m_iExtraOpenRangedAttackMod;
FAutoVariable<int, CvUnit> m_iExtraRoughAttackPercent;
FAutoVariable<int, CvUnit> m_iExtraRoughRangedAttackMod;
FAutoVariable<int, CvUnit> m_iExtraAttackFortifiedMod;
FAutoVariable<int, CvUnit> m_iExtraAttackWoundedMod;
int m_iFlankAttackModifier;
FAutoVariable<int, CvUnit> m_iExtraOpenDefensePercent;
FAutoVariable<int, CvUnit> m_iExtraRoughDefensePercent;
FAutoVariable<int, CvUnit> m_iPillageChange;
FAutoVariable<int, CvUnit> m_iUpgradeDiscount;
FAutoVariable<int, CvUnit> m_iExperiencePercent;
FAutoVariable<int, CvUnit> m_iDropRange;
FAutoVariable<int, CvUnit> m_iAirSweepCapableCount;
FAutoVariable<int, CvUnit> m_iExtraNavalMoves;
FAutoVariable<int, CvUnit> m_iKamikazePercent;
FAutoVariable<int, CvUnit> m_iBaseCombat;
FAutoVariable<DirectionTypes, CvUnit> m_eFacingDirection;
FAutoVariable<int, CvUnit> m_iArmyId;
FAutoVariable<int, CvUnit> m_iIgnoreTerrainCostCount;
FAutoVariable<int, CvUnit> m_iRoughTerrainEndsTurnCount;
FAutoVariable<int, CvUnit> m_iEmbarkAbilityCount;
FAutoVariable<int, CvUnit> m_iHoveringUnitCount;
FAutoVariable<int, CvUnit> m_iFlatMovementCostCount;
FAutoVariable<int, CvUnit> m_iCanMoveImpassableCount;
FAutoVariable<int, CvUnit> m_iOnlyDefensiveCount;
FAutoVariable<int, CvUnit> m_iNoDefensiveBonusCount;
FAutoVariable<int, CvUnit> m_iNoCaptureCount;
FAutoVariable<int, CvUnit> m_iNukeImmuneCount;
FAutoVariable<int, CvUnit> m_iHiddenNationalityCount;
FAutoVariable<int, CvUnit> m_iAlwaysHostileCount;
FAutoVariable<int, CvUnit> m_iNoRevealMapCount;
FAutoVariable<int, CvUnit> m_iCanMoveAllTerrainCount;
FAutoVariable<int, CvUnit> m_iCanMoveAfterAttackingCount;
FAutoVariable<int, CvUnit> m_iFreePillageMoveCount;
int m_iHealOnPillageCount;
FAutoVariable<int, CvUnit> m_iHPHealedIfDefeatEnemy;
int m_iGoldenAgeValueFromKills;
FAutoVariable<int, CvUnit> m_iTacticalAIPlotX;
FAutoVariable<int, CvUnit> m_iTacticalAIPlotY;
FAutoVariable<int, CvUnit> m_iGarrisonCityID; // unused
FAutoVariable<int, CvUnit> m_iFlags;
FAutoVariable<int, CvUnit> m_iNumAttacks;
FAutoVariable<int, CvUnit> m_iAttacksMade;
FAutoVariable<int, CvUnit> m_iGreatGeneralCount;
int m_iGreatAdmiralCount;
FAutoVariable<int, CvUnit> m_iGreatGeneralModifier;
int m_iGreatGeneralReceivesMovementCount;
int m_iGreatGeneralCombatModifier;
int m_iIgnoreGreatGeneralBenefit;
int m_iIgnoreZOC;
FAutoVariable<int, CvUnit> m_iFriendlyLandsModifier;
FAutoVariable<int, CvUnit> m_iFriendlyLandsAttackModifier;
FAutoVariable<int, CvUnit> m_iOutsideFriendlyLandsModifier;
FAutoVariable<int, CvUnit> m_iHealIfDefeatExcludeBarbariansCount;
FAutoVariable<int, CvUnit> m_iNumInterceptions;
FAutoVariable<int, CvUnit> m_iMadeInterceptionCount;
int m_iEverSelectedCount;
int m_iSapperCount;
int m_iCanHeavyCharge;
int m_iNumExoticGoods;
FAutoVariable<bool, CvUnit> m_bPromotionReady;
FAutoVariable<bool, CvUnit> m_bDeathDelay;
FAutoVariable<bool, CvUnit> m_bCombatFocus;
FAutoVariable<bool, CvUnit> m_bInfoBarDirty;
FAutoVariable<bool, CvUnit> m_bNotConverting;
FAutoVariable<bool, CvUnit> m_bAirCombat;
FAutoVariable<bool, CvUnit> m_bSetUpForRangedAttack;
FAutoVariable<bool, CvUnit> m_bEmbarked;
FAutoVariable<bool, CvUnit> m_bAITurnProcessed;
FAutoVariable<TacticalAIMoveTypes, CvUnit> m_eTacticalMove;
FAutoVariable<PlayerTypes, CvUnit> m_eCapturingPlayer;
bool m_bCapturedAsIs;
FAutoVariable<UnitTypes, CvUnit> m_eLeaderUnitType;
FAutoVariable<InvisibleTypes, CvUnit> m_eInvisibleType;
FAutoVariable<InvisibleTypes, CvUnit> m_eSeeInvisibleType;
FAutoVariable<GreatPeopleDirectiveTypes, CvUnit> m_eGreatPeopleDirectiveType;
CvUnitEntry* m_pUnitInfo;
bool m_bWaitingForMove; ///< If true, the unit is busy visualizing its move.
IDInfo m_combatUnit;
IDInfo m_combatCity;
IDInfo m_transportUnit;
std::vector<int> m_extraDomainModifiers;
FAutoVariable<CvString, CvUnit> m_strNameIAmNotSupposedToBeUsedAnyMoreBecauseThisShouldNotBeCheckedAndWeNeedToPreserveSaveGameCompatibility;
FAutoVariable<CvString, CvUnit> m_strScriptData;
int m_iScenarioData;
CvUnitPromotions m_Promotions;
CvUnitReligion* m_pReligion;
FAutoVariable<std::vector<int>, CvUnit> m_terrainDoubleMoveCount;
FAutoVariable<std::vector<int>, CvUnit> m_featureDoubleMoveCount;
FAutoVariable<std::vector<int>, CvUnit> m_terrainImpassableCount;
FAutoVariable<std::vector<int>, CvUnit> m_featureImpassableCount;
FAutoVariable<std::vector<int>, CvUnit> m_extraTerrainAttackPercent;
FAutoVariable<std::vector<int>, CvUnit> m_extraTerrainDefensePercent;
FAutoVariable<std::vector<int>, CvUnit> m_extraFeatureAttackPercent;
FAutoVariable<std::vector<int>, CvUnit> m_extraFeatureDefensePercent;
FAutoVariable<std::vector<int>, CvUnit> m_extraUnitCombatModifier;
FAutoVariable<std::vector<int>, CvUnit> m_unitClassModifier;
int m_iMissionTimer;
FAutoVariable<int, CvUnit> m_iMissionAIX;
FAutoVariable<int, CvUnit> m_iMissionAIY;
FAutoVariable<MissionAITypes, CvUnit> m_eMissionAIType;
IDInfo m_missionAIUnit;
FAutoVariable<ActivityTypes, CvUnit> m_eActivityType;
FAutoVariable<AutomateTypes, CvUnit> m_eAutomateType;
FAutoVariable<UnitAITypes, CvUnit> m_eUnitAIType;
DestructionNotification<UnitHandle> m_destructionNotification;
UnitHandle m_thisHandle;
UnitMovementQueue m_unitMoveLocs;
bool m_bIgnoreDangerWakeup; // slewis - make this an autovariable when saved games are broken
int m_iEmbarkedAllWaterCount;
int m_iEmbarkExtraVisibility;
int m_iEmbarkDefensiveModifier;
int m_iCapitalDefenseModifier;
int m_iCapitalDefenseFalloff;
int m_iCityAttackPlunderModifier;
int m_iReligiousStrengthLossRivalTerritory;
int m_iTradeMissionInfluenceModifier;
int m_iTradeMissionGoldModifier;
int m_iMapLayer; // Which layer does the unit reside on for pathing/stacking/etc.
int m_iNumGoodyHutsPopped;
int m_iLastGameTurnAtFullHealth;
CvString m_strName;
GreatWorkType m_eGreatWork;
int m_iTourismBlastStrength;
mutable CvPathNodeArray m_kLastPath;
mutable uint m_uiLastPathCacheDest;
bool canAdvance(const CvPlot& pPlot, int iThreshold) const;
CvUnit* airStrikeTarget(CvPlot& pPlot, bool bNoncombatAllowed) const;
bool CanWithdrawFromMelee(CvUnit& pAttacker);
bool DoWithdrawFromMelee(CvUnit& pAttacker);
// these are do to a unit using Heavy Charge against you
bool CanFallBackFromMelee(CvUnit& pAttacker);
bool DoFallBackFromMelee(CvUnit& pAttacker);
private:
mutable MissionQueue m_missionQueue;
};
FDataStream& operator<<(FDataStream&, const CvUnit&);
FDataStream& operator>>(FDataStream&, CvUnit&);
namespace FSerialization
{
void SyncUnits();
void ClearUnitDeltas();
}
#endif
| [
"ninakoru@gmx.com"
] | ninakoru@gmx.com |
708fef3d586f4fc6811bf929edca7fab67b9af8e | c908bf928a89cd3d6a5fc0cca3875d2a2257f9ed | /samples/queueinglib/Job_m.cc | 5bc686a404abc5b8ac1540803d68c3c8d755b8a7 | [] | no_license | alainrk/omnetppsds | 707013b46b5080f7a5925a7e5d6cde0a973e5786 | 123702cd2335481a808aa413082c8122d2ed4987 | refs/heads/master | 2020-07-04T14:03:32.814753 | 2014-11-14T18:46:13 | 2014-11-14T18:46:13 | 25,935,380 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 12,462 | cc | //
// Generated file, do not edit! Created by opp_msgc 4.5 from Job.msg.
//
// Disable warnings about unused variables, empty switch stmts, etc:
#ifdef _MSC_VER
# pragma warning(disable:4101)
# pragma warning(disable:4065)
#endif
#include <iostream>
#include <sstream>
#include "Job_m.h"
USING_NAMESPACE
// Another default rule (prevents compiler from choosing base class' doPacking())
template<typename T>
void doPacking(cCommBuffer *, T& t) {
throw cRuntimeError("Parsim error: no doPacking() function for type %s or its base class (check .msg and _m.cc/h files!)",opp_typename(typeid(t)));
}
template<typename T>
void doUnpacking(cCommBuffer *, T& t) {
throw cRuntimeError("Parsim error: no doUnpacking() function for type %s or its base class (check .msg and _m.cc/h files!)",opp_typename(typeid(t)));
}
namespace queueing {
// Template rule for outputting std::vector<T> types
template<typename T, typename A>
inline std::ostream& operator<<(std::ostream& out, const std::vector<T,A>& vec)
{
out.put('{');
for(typename std::vector<T,A>::const_iterator it = vec.begin(); it != vec.end(); ++it)
{
if (it != vec.begin()) {
out.put(','); out.put(' ');
}
out << *it;
}
out.put('}');
char buf[32];
sprintf(buf, " (size=%u)", (unsigned int)vec.size());
out.write(buf, strlen(buf));
return out;
}
// Template rule which fires if a struct or class doesn't have operator<<
template<typename T>
inline std::ostream& operator<<(std::ostream& out,const T&) {return out;}
Job_Base::Job_Base(const char *name, int kind) : ::cMessage(name,kind)
{
this->priority_var = 0;
this->totalQueueingTime_var = 0;
this->totalServiceTime_var = 0;
this->totalDelayTime_var = 0;
this->queueCount_var = 0;
this->delayCount_var = 0;
this->generation_var = 0;
}
Job_Base::Job_Base(const Job_Base& other) : ::cMessage(other)
{
copy(other);
}
Job_Base::~Job_Base()
{
}
Job_Base& Job_Base::operator=(const Job_Base& other)
{
if (this==&other) return *this;
::cMessage::operator=(other);
copy(other);
return *this;
}
void Job_Base::copy(const Job_Base& other)
{
this->priority_var = other.priority_var;
this->totalQueueingTime_var = other.totalQueueingTime_var;
this->totalServiceTime_var = other.totalServiceTime_var;
this->totalDelayTime_var = other.totalDelayTime_var;
this->queueCount_var = other.queueCount_var;
this->delayCount_var = other.delayCount_var;
this->generation_var = other.generation_var;
}
void Job_Base::parsimPack(cCommBuffer *b)
{
::cMessage::parsimPack(b);
doPacking(b,this->priority_var);
doPacking(b,this->totalQueueingTime_var);
doPacking(b,this->totalServiceTime_var);
doPacking(b,this->totalDelayTime_var);
doPacking(b,this->queueCount_var);
doPacking(b,this->delayCount_var);
doPacking(b,this->generation_var);
}
void Job_Base::parsimUnpack(cCommBuffer *b)
{
::cMessage::parsimUnpack(b);
doUnpacking(b,this->priority_var);
doUnpacking(b,this->totalQueueingTime_var);
doUnpacking(b,this->totalServiceTime_var);
doUnpacking(b,this->totalDelayTime_var);
doUnpacking(b,this->queueCount_var);
doUnpacking(b,this->delayCount_var);
doUnpacking(b,this->generation_var);
}
int Job_Base::getPriority() const
{
return priority_var;
}
void Job_Base::setPriority(int priority)
{
this->priority_var = priority;
}
simtime_t Job_Base::getTotalQueueingTime() const
{
return totalQueueingTime_var;
}
void Job_Base::setTotalQueueingTime(simtime_t totalQueueingTime)
{
this->totalQueueingTime_var = totalQueueingTime;
}
simtime_t Job_Base::getTotalServiceTime() const
{
return totalServiceTime_var;
}
void Job_Base::setTotalServiceTime(simtime_t totalServiceTime)
{
this->totalServiceTime_var = totalServiceTime;
}
simtime_t Job_Base::getTotalDelayTime() const
{
return totalDelayTime_var;
}
void Job_Base::setTotalDelayTime(simtime_t totalDelayTime)
{
this->totalDelayTime_var = totalDelayTime;
}
int Job_Base::getQueueCount() const
{
return queueCount_var;
}
void Job_Base::setQueueCount(int queueCount)
{
this->queueCount_var = queueCount;
}
int Job_Base::getDelayCount() const
{
return delayCount_var;
}
void Job_Base::setDelayCount(int delayCount)
{
this->delayCount_var = delayCount;
}
int Job_Base::getGeneration() const
{
return generation_var;
}
void Job_Base::setGeneration(int generation)
{
this->generation_var = generation;
}
class JobDescriptor : public cClassDescriptor
{
public:
JobDescriptor();
virtual ~JobDescriptor();
virtual bool doesSupport(cObject *obj) const;
virtual const char *getProperty(const char *propertyname) const;
virtual int getFieldCount(void *object) const;
virtual const char *getFieldName(void *object, int field) const;
virtual int findField(void *object, const char *fieldName) const;
virtual unsigned int getFieldTypeFlags(void *object, int field) const;
virtual const char *getFieldTypeString(void *object, int field) const;
virtual const char *getFieldProperty(void *object, int field, const char *propertyname) const;
virtual int getArraySize(void *object, int field) const;
virtual std::string getFieldAsString(void *object, int field, int i) const;
virtual bool setFieldAsString(void *object, int field, int i, const char *value) const;
virtual const char *getFieldStructName(void *object, int field) const;
virtual void *getFieldStructPointer(void *object, int field, int i) const;
};
Register_ClassDescriptor(JobDescriptor);
JobDescriptor::JobDescriptor() : cClassDescriptor("queueing::Job", "cMessage")
{
}
JobDescriptor::~JobDescriptor()
{
}
bool JobDescriptor::doesSupport(cObject *obj) const
{
return dynamic_cast<Job_Base *>(obj)!=NULL;
}
const char *JobDescriptor::getProperty(const char *propertyname) const
{
if (!strcmp(propertyname,"customize")) return "true";
cClassDescriptor *basedesc = getBaseClassDescriptor();
return basedesc ? basedesc->getProperty(propertyname) : NULL;
}
int JobDescriptor::getFieldCount(void *object) const
{
cClassDescriptor *basedesc = getBaseClassDescriptor();
return basedesc ? 7+basedesc->getFieldCount(object) : 7;
}
unsigned int JobDescriptor::getFieldTypeFlags(void *object, int field) const
{
cClassDescriptor *basedesc = getBaseClassDescriptor();
if (basedesc) {
if (field < basedesc->getFieldCount(object))
return basedesc->getFieldTypeFlags(object, field);
field -= basedesc->getFieldCount(object);
}
static unsigned int fieldTypeFlags[] = {
FD_ISEDITABLE,
FD_ISEDITABLE,
FD_ISEDITABLE,
FD_ISEDITABLE,
FD_ISEDITABLE,
FD_ISEDITABLE,
FD_ISEDITABLE,
};
return (field>=0 && field<7) ? fieldTypeFlags[field] : 0;
}
const char *JobDescriptor::getFieldName(void *object, int field) const
{
cClassDescriptor *basedesc = getBaseClassDescriptor();
if (basedesc) {
if (field < basedesc->getFieldCount(object))
return basedesc->getFieldName(object, field);
field -= basedesc->getFieldCount(object);
}
static const char *fieldNames[] = {
"priority",
"totalQueueingTime",
"totalServiceTime",
"totalDelayTime",
"queueCount",
"delayCount",
"generation",
};
return (field>=0 && field<7) ? fieldNames[field] : NULL;
}
int JobDescriptor::findField(void *object, const char *fieldName) const
{
cClassDescriptor *basedesc = getBaseClassDescriptor();
int base = basedesc ? basedesc->getFieldCount(object) : 0;
if (fieldName[0]=='p' && strcmp(fieldName, "priority")==0) return base+0;
if (fieldName[0]=='t' && strcmp(fieldName, "totalQueueingTime")==0) return base+1;
if (fieldName[0]=='t' && strcmp(fieldName, "totalServiceTime")==0) return base+2;
if (fieldName[0]=='t' && strcmp(fieldName, "totalDelayTime")==0) return base+3;
if (fieldName[0]=='q' && strcmp(fieldName, "queueCount")==0) return base+4;
if (fieldName[0]=='d' && strcmp(fieldName, "delayCount")==0) return base+5;
if (fieldName[0]=='g' && strcmp(fieldName, "generation")==0) return base+6;
return basedesc ? basedesc->findField(object, fieldName) : -1;
}
const char *JobDescriptor::getFieldTypeString(void *object, int field) const
{
cClassDescriptor *basedesc = getBaseClassDescriptor();
if (basedesc) {
if (field < basedesc->getFieldCount(object))
return basedesc->getFieldTypeString(object, field);
field -= basedesc->getFieldCount(object);
}
static const char *fieldTypeStrings[] = {
"int",
"simtime_t",
"simtime_t",
"simtime_t",
"int",
"int",
"int",
};
return (field>=0 && field<7) ? fieldTypeStrings[field] : NULL;
}
const char *JobDescriptor::getFieldProperty(void *object, int field, const char *propertyname) const
{
cClassDescriptor *basedesc = getBaseClassDescriptor();
if (basedesc) {
if (field < basedesc->getFieldCount(object))
return basedesc->getFieldProperty(object, field, propertyname);
field -= basedesc->getFieldCount(object);
}
switch (field) {
default: return NULL;
}
}
int JobDescriptor::getArraySize(void *object, int field) const
{
cClassDescriptor *basedesc = getBaseClassDescriptor();
if (basedesc) {
if (field < basedesc->getFieldCount(object))
return basedesc->getArraySize(object, field);
field -= basedesc->getFieldCount(object);
}
Job_Base *pp = (Job_Base *)object; (void)pp;
switch (field) {
default: return 0;
}
}
std::string JobDescriptor::getFieldAsString(void *object, int field, int i) const
{
cClassDescriptor *basedesc = getBaseClassDescriptor();
if (basedesc) {
if (field < basedesc->getFieldCount(object))
return basedesc->getFieldAsString(object,field,i);
field -= basedesc->getFieldCount(object);
}
Job_Base *pp = (Job_Base *)object; (void)pp;
switch (field) {
case 0: return long2string(pp->getPriority());
case 1: return double2string(pp->getTotalQueueingTime());
case 2: return double2string(pp->getTotalServiceTime());
case 3: return double2string(pp->getTotalDelayTime());
case 4: return long2string(pp->getQueueCount());
case 5: return long2string(pp->getDelayCount());
case 6: return long2string(pp->getGeneration());
default: return "";
}
}
bool JobDescriptor::setFieldAsString(void *object, int field, int i, const char *value) const
{
cClassDescriptor *basedesc = getBaseClassDescriptor();
if (basedesc) {
if (field < basedesc->getFieldCount(object))
return basedesc->setFieldAsString(object,field,i,value);
field -= basedesc->getFieldCount(object);
}
Job_Base *pp = (Job_Base *)object; (void)pp;
switch (field) {
case 0: pp->setPriority(string2long(value)); return true;
case 1: pp->setTotalQueueingTime(string2double(value)); return true;
case 2: pp->setTotalServiceTime(string2double(value)); return true;
case 3: pp->setTotalDelayTime(string2double(value)); return true;
case 4: pp->setQueueCount(string2long(value)); return true;
case 5: pp->setDelayCount(string2long(value)); return true;
case 6: pp->setGeneration(string2long(value)); return true;
default: return false;
}
}
const char *JobDescriptor::getFieldStructName(void *object, int field) const
{
cClassDescriptor *basedesc = getBaseClassDescriptor();
if (basedesc) {
if (field < basedesc->getFieldCount(object))
return basedesc->getFieldStructName(object, field);
field -= basedesc->getFieldCount(object);
}
switch (field) {
default: return NULL;
};
}
void *JobDescriptor::getFieldStructPointer(void *object, int field, int i) const
{
cClassDescriptor *basedesc = getBaseClassDescriptor();
if (basedesc) {
if (field < basedesc->getFieldCount(object))
return basedesc->getFieldStructPointer(object, field, i);
field -= basedesc->getFieldCount(object);
}
Job_Base *pp = (Job_Base *)object; (void)pp;
switch (field) {
default: return NULL;
}
}
}; // end namespace queueing
| [
"alain.narko@gmail.com"
] | alain.narko@gmail.com |
1b85cfb749da35bd088876c6baab1bface5b9efb | 713530bcd0cf43dd35aa15f04a3bce1c597ce8f7 | /UnixTest/FileOut.h | e36ba3cac4c8413f80a2e9374d03580f3609d644 | [] | no_license | Jamescwg/CrossPlatformFileIO | c14f70e017745deafd72d754abb2f52d35668195 | d97568f59fc1a446079cfa0031dee8cbcb7d5555 | refs/heads/master | 2020-03-19T12:08:55.970002 | 2018-06-07T10:25:00 | 2018-06-07T10:25:00 | null | 0 | 0 | null | null | null | null | GB18030 | C++ | false | false | 2,364 | h | /**
* FileName:FileOut.h
* Description:文件写入类(重载运算符<<)
* Author:ZiQin
* DateTime:2018-6-1
* Version:v1.0.0
*/
#ifndef FILEOUT_H_
#define FILEOUT_H_
#include <cstring>
#include <string>
#include <sstream>
#include "BaseFileIO.h"
/**
* 符号常量说明:
* f_bin 文件读写以字节流的形式
*/
#define f_bin true
class FileOut : public BaseFileIO {
private:
int latestWrittenSize; // 最近一次写入文件的字节大小
bool bin; // 文件读是否以字节流的形式
public:
// 构造函数
FileOut();
/* 参数:
fileName:文件路径
visitMode:访问模式(f_in/f_out)
op:打开方式(f_exist/f_new)
binary:是否以字节流的形式读取文件(默认字符流)
*/
FileOut(std::string fileName, _mode_code visitMode, _mode_code op, bool bin = false);
virtual ~FileOut();
/**
* 函数名:getLatestWrittenSize
* 功能:获取最近一次写入文件的字节大小
* 参数:无
* 返回值:最近一次写入文件的字节大小
*/
int getLatestWrittenSize();
/**
* 函数名:openFile
* 功能:打开文件
* 参数:
fileName:文件路径
visitMode:访问模式(f_in/f_out)
op:打开方式(f_exist/f_new)
binary:是否以字节流的形式读入(默认字符流)
* 返回值:打开成功或失败
*/
bool openFile(std::string filePath, _mode_code visitMode, _mode_code op, bool bin = false);
/**
* 友元函数:<<运算符重载
* 功能:将第二个参数的内容写入到文件中
*/
friend FileOut & operator << (FileOut & fop, int & number);
friend FileOut & operator << (FileOut & fop, double & number);
friend FileOut & operator << (FileOut & fop, char & ch);
friend FileOut & operator << (FileOut & fop, const std::string & str);
/**
* 函数名:isBinaryVisit
* 功能:检查当前文件访问是否以字节流的形式
* 参数:无
* 返回值:是否以字节流的形式访问
*/
bool isBinaryVisit();
private:
/**
* 函数名:numToStr
* 功能:整数转字符串
* 参数:将要转换的整数
* 返回值:转换结果
*/
std::string numToStr(const int number);
/**
* 函数名:numToStr
* 功能:浮点数转字符串
* 参数:将要转换的浮点数
* 返回值:转换结果
*/
std::string numToStr(const double number);
};
#endif
| [
"ziqin9510@163.com"
] | ziqin9510@163.com |
801ad4bdf6d265796451df2ba7c456deefaaad39 | aa0e2de778d1f27fa307a400d9a0a2d424c33b6c | /comment_counter_test_suite/test_2.cpp | a0fd974552e43543038866d268705628921531b6 | [] | no_license | tooyoungtoosimplesometimesnaive/code_base_snapshot | 045618e88b6145aa14446d320a362be165541f85 | 708f47c6b5b52ab69406df8377dce72e05760f2c | refs/heads/master | 2021-05-12T18:00:31.778117 | 2018-01-26T06:11:32 | 2018-01-26T06:11:32 | 117,058,194 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 26 | cpp | /*
comment */
int a = 0;
| [
"xingmarc@yeah.net"
] | xingmarc@yeah.net |
6df2ca480516fccae26631daa30412efe38ef46f | 471c8c40cb8b2b959bbcc97ffecc9f768de2576f | /main.cpp | ddf6159d6423c6a9d447262a5b7e01d1544bd8c9 | [] | no_license | sToor16/Longest-Common-Substring | 6c5edec43ace5e71d59872561e74c08de14d2776 | e395bee59f12ac33d9627de4cda69a44f940d0d2 | refs/heads/master | 2020-03-21T17:10:36.611199 | 2018-06-27T02:22:24 | 2018-06-27T02:22:24 | 138,817,781 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 5,222 | cpp | // Use suffix array and LCP to compute
// longest common substring of two input strings. BPW
/*
* This program has been successfuly complied and runs on omega
* The c++ version used was 11
* CLion IDE was used to write the code
* To make the code work simply copy the code and run in an ide
* IF any compiliation error occur, please let me know
* ID-1001564975
* email-shubhpreetsingh.toor@mavs.uta.edu
*/
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <iostream>
char s[1000000],s1[500000],s2[500000],s3[50000];
int n, // length of s[] including \0
sa[1000000], // suffix array for s[]
rank[1000000], // rank[i] gives the rank (subscript) of s[i] in sa[]
lcp[1000000]; // lcp[i] indicates the number of identical prefix symbols
// for s[sa[i-1]] and s[sa[i]]
int suffixCompare(const void *xVoidPt,const void *yVoidPt)
{
// Used in qsort call to generate suffix array.
int *xPt=(int*) xVoidPt,*yPt=(int*) yVoidPt;
return strcmp(&s[*xPt],&s[*yPt]);
}
void computeRank()
{
// Computes rank as the inverse permutation of the suffix array
int i;
for (i=0;i<n;i++)
rank[sa[i]]=i;
}
void computeLCP()
{
//Kasai et al linear-time construction
int h,i,j,k;
h=0; // Index to support result that lcp[rank[i]]>=lcp[rank[i-1]]-1
for (i=0;i<n;i++)
{
k=rank[i];
if (k==0)
lcp[k]=(-1);
else
{
j=sa[k-1];
// Attempt to extend lcp
while (i+h<n && j+h<n && s[i+h]==s[j+h])
h++;
lcp[k]=h;
}
if (h>0)
h--; // Decrease according to result
}
}
int fibIndex=0;
int main()
{
int i,j,k,p,dollarPos,newElement,ampPos,LCSpos=0,LCSlength=0,firstPos,secondPos,thirdPos, tempStart, tempEnd;
scanf("%s",s1);
scanf("%s",s2);
scanf("%s",s3);
for (i=0;s1[i]!='\0';i++)
s[i]=s1[i];
dollarPos=i;
//std::cout << "dollarPos:" << dollarPos << std::endl;
s[i++]='$';
for (j=0;s2[j]!='\0';j++)
s[i+j]=s2[j];
ampPos = i+j;
s[i+j++] = '%';
for (newElement=0;s3[newElement]!='\0';newElement++)
s[i+j+newElement]=s3[newElement];
s[i+j+newElement]='\0';
n=i+j+newElement+1;
printf("n is %d\n",n);
// Quick-and-dirty suffix array construction
for (i=0;i<n;i++)
sa[i]=i;
qsort(sa,n,sizeof(int),suffixCompare);
computeRank();
computeLCP();
if (n<2000)
{
printf("i sa suffix lcp s rank lcp[rank]\n");
for (i=0;i<n;i++)
printf("%-3d %-3d %-35.35s %-3d %c %-3d %-3d\n",
i,sa[i],&s[sa[i]],lcp[i],s[i],rank[i],lcp[rank[i]]);
}
int checkArray[] = {0,0,0};
int startPos = 0;
int endPos;
int min = 0;
for (i=3;i<n;i++) {
if (sa[i]<dollarPos)
{
checkArray[0] = 1;
if (startPos == 0) {
startPos = i;
}
}
if (sa[i] < ampPos && sa[i] > dollarPos)
{
checkArray[1] = 1;
if (startPos == 0) {
startPos = i;
}
}
if (sa[i] > ampPos) {
checkArray[2] = 1;
if (startPos == 0) {
startPos = i;
}
}
if(checkArray[0] == 1 && checkArray[1] == 1 && checkArray[2] == 1)
{
checkArray[0] = checkArray[1] = checkArray [2] = 0;
if (sa[i-1]<dollarPos) {
checkArray[0] = 1;
}
if (sa[i-1] < ampPos && sa[i] > dollarPos) {
checkArray[1] = 1;
}
if (sa[i-1] > ampPos){
checkArray[2] = 1;
}
if (sa[i]<dollarPos) {
checkArray[0] = 1;
}
if (sa[i] < ampPos && sa[i] > dollarPos) {
checkArray[1] = 1;
}
if (sa[i] > ampPos){
checkArray[2] = 1;
}
int tempMin = std::min (lcp[i-1],lcp[i]);
if (tempMin > min) {
min = tempMin;
LCSpos=i;
tempStart = startPos;
tempEnd = i;
}
startPos = i-1;
}
}
int x;
for (x=tempStart;x<=tempEnd;x++) {
if (sa[x] < dollarPos ) {
firstPos = x;
}
if (sa[x] > dollarPos && sa[x] < ampPos) {
secondPos = x;
}
if (sa[x] > ampPos) {
thirdPos = x;
}
}
if (firstPos > thirdPos)
std::swap(firstPos, thirdPos);
if (firstPos > secondPos)
std::swap(firstPos, secondPos);
if (secondPos > thirdPos)
std::swap(secondPos, thirdPos);
printf("Length of longest common substring is %d\n",min);
printf("x at %d, y at %d, z at %d\n",firstPos, secondPos, thirdPos);
for (i=0;i<min;i++)
printf("%c",s[sa[LCSpos]+i]);
printf("\n");
}
| [
"toor@Toors-MacBook-Pro.local"
] | toor@Toors-MacBook-Pro.local |
0930eaf4fba63c64bf15224e89a1196aef062e4a | 2b309dadb0b3774472eb546c132bd87bdbf334fe | /hex-pecs/src/os.h | bc0faeb936c610386882aa99eaa53f97e3e1bab1 | [] | no_license | albandil/Hex | ee35951c8e0b3ec0009c710f392e2027be915eff | 6585c5ac3e2543b5b0a6819d52b40ba9da7400a1 | refs/heads/master | 2021-08-27T18:05:57.032730 | 2021-08-01T06:39:46 | 2021-08-01T06:39:46 | 132,655,225 | 2 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,716 | h | // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
// //
// / / / / __ \ \ / / //
// / /__ / / / _ \ \ \/ / //
// / ___ / | |/_/ / /\ \ //
// / / / / \_\ / / \ \ //
// //
// //
// Copyright (c) 2015, Jakub Benda, Charles University in Prague //
// //
// MIT License: //
// //
// Permission is hereby granted, free of charge, to any person obtaining a //
// copy of this software and associated documentation files (the "Software"), //
// to deal in the Software without restriction, including without limitation //
// the rights to use, copy, modify, merge, publish, distribute, sublicense, //
// and/or sell copies of the Software, and to permit persons to whom the //
// Software is furnished to do so, subject to the following conditions: //
// //
// The above copyright notice and this permission notice shall be included //
// in all copies or substantial portions of the Software. //
// //
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS //
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, //
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE //
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, //
// WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF //
// OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. //
// //
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
#include <string>
namespace os
{
bool mkdirp (std::string dirname);
}
| [
"jakub.benda@seznam.cz"
] | jakub.benda@seznam.cz |
e3cc7899e8352804b66c24cc6799f6a41c3d8a23 | 6e0be5b324afc8470e29c28006ecaf134076ff0e | /deps/prebuilt/include/icu/unicode/curramt.h | e1b07d9be125deec29bd751b2da1761221798ff1 | [
"MIT"
] | permissive | Bhaskers-Blu-Org2/WinObjC | 3abe3a338738ad607ca658edee1bcfcb542fe69f | ea3f7983803fa02309f974ff878b6c9ecc72c7c4 | refs/heads/develop | 2022-04-03T15:19:31.807607 | 2020-01-06T16:33:43 | 2020-01-06T16:47:55 | 276,100,793 | 0 | 1 | MIT | 2020-06-30T13:05:08 | 2020-06-30T13:05:07 | null | UTF-8 | C++ | false | false | 3,613 | h | /*
**********************************************************************
* Copyright (c) 2004-2006, International Business Machines
* Corporation and others. All Rights Reserved.
**********************************************************************
* Author: Alan Liu
* Created: April 26, 2004
* Since: ICU 3.0
**********************************************************************
*/
#ifndef __CURRENCYAMOUNT_H__
#define __CURRENCYAMOUNT_H__
#include "unicode/utypes.h"
#if !UCONFIG_NO_FORMATTING
#include "unicode/measure.h"
#include "unicode/currunit.h"
/**
* \file
* \brief C++ API: Currency Amount Object.
*/
U_NAMESPACE_BEGIN
/**
*
* A currency together with a numeric amount, such as 200 USD.
*
* @author Alan Liu
* @stable ICU 3.0
*/
class U_I18N_API CurrencyAmount : public Measure {
public:
/**
* Construct an object with the given numeric amount and the given
* ISO currency code.
* @param amount a numeric object; amount.isNumeric() must be TRUE
* @param isoCode the 3-letter ISO 4217 currency code; must not be
* NULL and must have length 3
* @param ec input-output error code. If the amount or the isoCode
* is invalid, then this will be set to a failing value.
* @stable ICU 3.0
*/
CurrencyAmount(const Formattable& amount, const UChar* isoCode, UErrorCode& ec);
/**
* Construct an object with the given numeric amount and the given
* ISO currency code.
* @param amount the amount of the given currency
* @param isoCode the 3-letter ISO 4217 currency code; must not be
* NULL and must have length 3
* @param ec input-output error code. If the isoCode is invalid,
* then this will be set to a failing value.
* @stable ICU 3.0
*/
CurrencyAmount(double amount, const UChar* isoCode, UErrorCode& ec);
/**
* Copy constructor
* @stable ICU 3.0
*/
CurrencyAmount(const CurrencyAmount& other);
/**
* Assignment operator
* @stable ICU 3.0
*/
CurrencyAmount& operator=(const CurrencyAmount& other);
/**
* Return a polymorphic clone of this object. The result will
* have the same class as returned by getDynamicClassID().
* @stable ICU 3.0
*/
virtual UObject* clone() const;
/**
* Destructor
* @stable ICU 3.0
*/
virtual ~CurrencyAmount();
/**
* Returns a unique class ID for this object POLYMORPHICALLY.
* This method implements a simple form of RTTI used by ICU.
* @return The class ID for this object. All objects of a given
* class have the same class ID. Objects of other classes have
* different class IDs.
* @stable ICU 3.0
*/
virtual UClassID getDynamicClassID() const;
/**
* Returns the class ID for this class. This is used to compare to
* the return value of getDynamicClassID().
* @return The class ID for all objects of this class.
* @stable ICU 3.0
*/
static UClassID U_EXPORT2 getStaticClassID();
/**
* Return the currency unit object of this object.
* @stable ICU 3.0
*/
inline const CurrencyUnit& getCurrency() const;
/**
* Return the ISO currency code of this object.
* @stable ICU 3.0
*/
inline const UChar* getISOCurrency() const;
};
inline const CurrencyUnit& CurrencyAmount::getCurrency() const {
return (const CurrencyUnit&)getUnit();
}
inline const UChar* CurrencyAmount::getISOCurrency() const {
return getCurrency().getISOCurrency();
}
U_NAMESPACE_END
#endif // !UCONFIG_NO_FORMATTING
#endif // __CURRENCYAMOUNT_H__
| [
"rajsesh@microsoft.com"
] | rajsesh@microsoft.com |
4896e470f840114173e2ebf2c19cf4521d771785 | 6b40e9dccf2edc767c44df3acd9b626fcd586b4d | /NT/printscan/faxsrv/util/version.cpp | 8755e99eeb72f0430346063bf73f121b117048cb | [] | no_license | jjzhang166/WinNT5_src_20201004 | 712894fcf94fb82c49e5cd09d719da00740e0436 | b2db264153b80fbb91ef5fc9f57b387e223dbfc2 | refs/heads/Win2K3 | 2023-08-12T01:31:59.670176 | 2021-10-14T15:14:37 | 2021-10-14T15:14:37 | 586,134,273 | 1 | 0 | null | 2023-01-07T03:47:45 | 2023-01-07T03:47:44 | null | UTF-8 | C++ | false | false | 5,813 | cpp | /*++
Copyright (c) 2001 Microsoft Corporation
Module Name:
string.c
Abstract:
This file implements version functions for fax.
Author:
Eran Yariv (erany) 30-Oct-2001
Environment:
User Mode
--*/
#include <windows.h>
#include <tchar.h>
#include <stdlib.h>
#include "faxutil.h"
#include "faxreg.h"
DWORD
GetFileVersion (
LPCTSTR lpctstrFileName,
PFAX_VERSION pVersion
)
/*++
Routine name : GetFileVersion
Routine description:
Fills a FAX_VERSION structure with data about a given file module
Author:
Eran Yariv (EranY), Nov, 1999
Arguments:
lpctstrFileName [in ] - File name
pVersion [out] - Version information
Return Value:
Standard Win32 error
--*/
{
DWORD dwRes = ERROR_SUCCESS;
DWORD dwVerInfoSize;
DWORD dwVerHnd=0; // An ignored parameter, always 0
LPBYTE lpbVffInfo = NULL;
VS_FIXEDFILEINFO *pFixedFileInfo;
UINT uVersionDataLength;
DEBUG_FUNCTION_NAME(TEXT("GetFileVersion"));
if (!pVersion)
{
return ERROR_INVALID_PARAMETER;
}
if (sizeof (FAX_VERSION) != pVersion->dwSizeOfStruct)
{
//
// Size mismatch
//
return ERROR_INVALID_PARAMETER;
}
pVersion->bValid = FALSE;
//
// Find size needed for version information
//
dwVerInfoSize = GetFileVersionInfoSize ((LPTSTR)lpctstrFileName, &dwVerHnd);
if (0 == dwVerInfoSize)
{
dwRes = GetLastError ();
DebugPrintEx(
DEBUG_ERR,
TEXT("GetFileVersionInfoSize() failed . dwRes = %ld"),
dwRes);
return dwRes;
}
//
// Allocate memory for file version info
//
lpbVffInfo = (LPBYTE)MemAlloc (dwVerInfoSize);
if (NULL == lpbVffInfo)
{
DebugPrintEx(
DEBUG_ERR,
TEXT("Cant allocate %ld bytes"),
dwVerInfoSize);
return ERROR_NOT_ENOUGH_MEMORY;
}
//
// Try to get the version info
//
if (!GetFileVersionInfo(
(LPTSTR)lpctstrFileName,
dwVerHnd,
dwVerInfoSize,
(LPVOID)lpbVffInfo))
{
dwRes = GetLastError ();
DebugPrintEx(
DEBUG_ERR,
TEXT("GetFileVersionInfo() failed . dwRes = %ld"),
dwRes);
goto exit;
}
//
// Query the required version structure
//
if (!VerQueryValue (
(LPVOID)lpbVffInfo,
TEXT ("\\"), // Retrieve the VS_FIXEDFILEINFO struct
(LPVOID *)&pFixedFileInfo,
&uVersionDataLength))
{
dwRes = GetLastError ();
DebugPrintEx(
DEBUG_ERR,
TEXT("VerQueryValue() failed . dwRes = %ld"),
dwRes);
goto exit;
}
pVersion->dwFlags = (pFixedFileInfo->dwFileFlags & VS_FF_DEBUG) ? FAX_VER_FLAG_CHECKED : 0;
pVersion->wMajorVersion = WORD((pFixedFileInfo->dwProductVersionMS) >> 16);
pVersion->wMinorVersion = WORD((pFixedFileInfo->dwProductVersionMS) & 0x0000ffff);
pVersion->wMajorBuildNumber = WORD((pFixedFileInfo->dwProductVersionLS) >> 16);
pVersion->wMinorBuildNumber = WORD((pFixedFileInfo->dwProductVersionLS) & 0x0000ffff);
pVersion->bValid = TRUE;
Assert (ERROR_SUCCESS == dwRes);
exit:
if (lpbVffInfo)
{
MemFree (lpbVffInfo);
}
return dwRes;
} // GetFileVersion
#define REG_KEY_IE _T("Software\\Microsoft\\Internet Explorer")
#define REG_VAL_IE_VERSION _T("Version")
///////////////////////////////////////////////////////////////////////////////////////
// Function:
// GetVersionIE
//
// Purpose:
// Find out the version of IE that is installed on this machine.
// This function can be used on any platform.
// For versions less than 4.0 this function always returns 1.0
//
// Params:
// BOOL* fInstalled - out param, is IE installed?
// INT* iMajorVersion - out param, the major version of IE
// INT* iMinorVersion - out param, the minor version of IE
//
// Return Value:
// ERROR_SUCCESS - in case of success
// Win32 Error code - in case of failure
//
// Author:
// Mooly Beery (MoolyB) 19-May-2002
///////////////////////////////////////////////////////////////////////////////////////
DWORD GetVersionIE(BOOL* fInstalled, INT* iMajorVersion, INT* iMinorVersion)
{
DWORD dwRet = ERROR_SUCCESS;
LPTSTR lptstrVersion = NULL;
HKEY hKey = NULL;
(*fInstalled) = FALSE;
(*iMajorVersion) = 1;
(*iMinorVersion) = 0;
hKey = OpenRegistryKey(HKEY_LOCAL_MACHINE,REG_KEY_IE,KEY_READ,FALSE);
if (!hKey)
{
// IE is not installed at all.
goto exit;
}
(*fInstalled) = TRUE;
lptstrVersion = GetRegistryString(hKey,REG_VAL_IE_VERSION,NULL);
if (!lptstrVersion)
{
// no Version entry, this means IE version is less than 4.0
goto exit;
}
// the version is formatted: <major version>.<minor version>.<major build>.<minor build>
LPTSTR lptsrtFirstDot = _tcschr(lptstrVersion,_T('.'));
if (!lptsrtFirstDot)
{
// something is wrong in the format.
dwRet = ERROR_BAD_FORMAT;
goto exit;
}
(*lptsrtFirstDot++) = 0;
(*iMajorVersion) = _ttoi(lptstrVersion);
LPTSTR lptsrtSecondDot = _tcschr(lptsrtFirstDot,_T('.'));
if (!lptsrtSecondDot)
{
// something is wrong in the format.
dwRet = ERROR_BAD_FORMAT;
goto exit;
}
(*lptsrtSecondDot) = 0;
(*iMinorVersion) = _ttoi(lptsrtFirstDot);
exit:
if (hKey)
{
RegCloseKey(hKey);
}
if (lptstrVersion)
{
MemFree(lptstrVersion);
}
return dwRet;
}
| [
"seta7D5@protonmail.com"
] | seta7D5@protonmail.com |
8304d52cf9bbb4686a0c02a11da023f6dbc14e21 | da94b9bd63a9eb355e41385521c7ba43b3c43cf9 | /test/Common/utest-parallel-collective-broadcast.hpp | 3618236ba31f817674de3ccf9794de5bdc6204ac | [] | no_license | zhanggjun/coolfluid3 | 9630cc4c4e6176d818ad20c9835ba053ce7c7175 | 04a180e1f8fdc20018dd297c00a273462e686d03 | refs/heads/master | 2023-03-26T02:54:11.595910 | 2011-08-09T07:52:37 | 2011-08-09T07:52:37 | 526,964,683 | 1 | 0 | null | 2022-08-20T15:25:58 | 2022-08-20T15:25:57 | null | UTF-8 | C++ | false | false | 10,960 | hpp | // Copyright (C) 2010 von Karman Institute for Fluid Dynamics, Belgium
//
// This software is distributed under the terms of the
// GNU Lesser General Public License version 3 (LGPLv3).
// See doc/lgpl.txt and doc/gpl.txt for the license text.
// this file is en-block included into utest-parallel-collective.cpp
// do not include anything here, rather in utest-parallel-collective.cpp
////////////////////////////////////////////////////////////////////////////////
struct PEBroadcastFixture
{
/// common setup for each test case
PEBroadcastFixture()
{
int i;
// rank and proc
nproc=mpi::PE::instance().size();
irank=mpi::PE::instance().rank();
// ptr helpers
sndcnt=0;
rcvcnt=0;
ptr_snddat=new double[nproc];
ptr_rcvdat=new double[nproc*nproc];
ptr_sndmap=new int[nproc];
ptr_rcvmap=new int[nproc];
ptr_tmprcv=new double[nproc];
// std::Vector helpers
vec_snddat.resize(nproc);
vec_rcvdat.resize(nproc*nproc);
vec_sndmap.resize(nproc);
vec_rcvmap.resize(nproc);
vec_tmprcv.resize(0);
vec_tmprcvchr.resize(nproc*sizeof(double));
vec_snddatchr.resize(nproc*sizeof(double));
}
/// common tear-down for each test case
~PEBroadcastFixture()
{
delete[] ptr_snddat;
delete[] ptr_rcvdat;
delete[] ptr_sndmap;
delete[] ptr_rcvmap;
delete[] ptr_tmprcv;
}
/// number of processes
int nproc;
/// rank of process
int irank;
/// data for raw pointers
int sndcnt;
int rcvcnt;
double* ptr_snddat;
double* ptr_rcvdat;
int* ptr_sndmap;
int* ptr_rcvmap;
double* ptr_tmprcv;
/// data for std::vectors
std::vector<double> vec_snddat;
std::vector<double> vec_rcvdat;
std::vector<int> vec_sndmap;
std::vector<int> vec_rcvmap;
std::vector<double> vec_tmprcv;
std::vector<char> vec_tmprcvchr;
std::vector<char> vec_snddatchr;
/// helper function for constant size data - setting up input and verification data
void setup_data_constant()
{
int i,j;
for (i=0; i<nproc; i++){
ptr_snddat[i]=(irank+1)*1000+(i+1);
for (j=0; j<nproc; j++) ptr_rcvdat[i*nproc+j]=(i+1)*1000+(j+1);
}
sndcnt=nproc;
rcvcnt=nproc;
vec_snddat.assign(ptr_snddat,ptr_snddat+nproc);
vec_rcvdat.assign(ptr_rcvdat,ptr_rcvdat+nproc*nproc);
vec_snddatchr.assign((char*)(ptr_snddat),(char*)(ptr_snddat+nproc));
}
/// helper function for variable size data - setting up input and verification data
void setup_data_variable()
{
int i,j,k,l;
sndcnt=nproc/2;
rcvcnt=nproc/2;
for(i=0; i<nproc; i++) { // making debugger shut up for uninitialized values
ptr_snddat[i]=0.;
ptr_sndmap[i]=0;
ptr_rcvmap[i]=0;
}
for(i=0; i<nproc; i++) for(j=0; j<nproc; j++) ptr_rcvdat[i*nproc+j]=0; // making debugger shut up for uninitialized values
for (i=0; i<nproc; i++){
ptr_snddat[i]=(irank+1)*1000+(i+1);
for (j=0; j<nproc; j++) ptr_rcvdat[i*nproc+j]=(i+1)*1000+(2*(rcvcnt-j)-1);
}
for (i=0; i<sndcnt; i++)
ptr_sndmap[i]=2*i; // every second
for (i=0; i<rcvcnt; i++)
ptr_rcvmap[i]=rcvcnt-1-i; // inverse into contiguous
vec_snddat.assign(ptr_snddat,ptr_snddat+nproc);
vec_rcvdat.assign(ptr_rcvdat,ptr_rcvdat+nproc*nproc);
vec_snddatchr.assign((char*)(ptr_snddat),(char*)(ptr_snddat+nproc));
vec_sndmap.assign(ptr_sndmap,ptr_sndmap+sndcnt);
vec_rcvmap.assign(ptr_rcvmap,ptr_rcvmap+rcvcnt);
}
};
////////////////////////////////////////////////////////////////////////////////
BOOST_FIXTURE_TEST_SUITE( PEBroadcastSuite, PEBroadcastFixture )
////////////////////////////////////////////////////////////////////////////////
BOOST_AUTO_TEST_CASE( Broadcast )
{
PEProcessSortedExecute(-1,CFinfo << "Testing broadcast " << irank << "/" << nproc << CFendl; );
}
////////////////////////////////////////////////////////////////////////////////
BOOST_AUTO_TEST_CASE( broadcast_ptr_constant )
{
int i,r;
setup_data_constant();
for (r=0; r<nproc; r++) {
delete[] ptr_tmprcv;
ptr_tmprcv=0;
ptr_tmprcv=mpi::PE::instance().broadcast(ptr_snddat, nproc, (double*)0, r);
for (i=0; i<nproc; i++) BOOST_CHECK_EQUAL( ptr_tmprcv[i] , ptr_rcvdat[r*nproc+i] );
for (i=0; i<nproc; i++) ptr_tmprcv[i]=0.;
mpi::PE::instance().broadcast(ptr_snddat, nproc, ptr_tmprcv, r);
for (i=0; i<nproc; i++) BOOST_CHECK_EQUAL( ptr_tmprcv[i] , ptr_rcvdat[r*nproc+i] );
for (i=0; i<nproc; i++) ptr_tmprcv[i]=ptr_snddat[i];
mpi::PE::instance().broadcast(ptr_tmprcv, nproc, ptr_tmprcv, r);
for (i=0; i<nproc; i++) BOOST_CHECK_EQUAL( ptr_tmprcv[i] , ptr_rcvdat[r*nproc+i] );
delete[] ptr_tmprcv;
ptr_tmprcv=0;
ptr_tmprcv=(double*)mpi::PE::instance().broadcast((char*)ptr_snddat, nproc, (char*)0, r, sizeof(double));
for (i=0; i<nproc; i++) BOOST_CHECK_EQUAL( ptr_tmprcv[i] , ptr_rcvdat[r*nproc+i] );
for (i=0; i<nproc; i++) ptr_tmprcv[i]=0.;
mpi::PE::instance().broadcast((char*)ptr_snddat, nproc, (char*)ptr_tmprcv, r, sizeof(double));
for (i=0; i<nproc; i++) BOOST_CHECK_EQUAL( ptr_tmprcv[i] , ptr_rcvdat[r*nproc+i] );
for (i=0; i<nproc; i++) ptr_tmprcv[i]=ptr_snddat[i];
mpi::PE::instance().broadcast((char*)ptr_tmprcv, nproc, (char*)ptr_tmprcv, r, sizeof(double));
for (i=0; i<nproc; i++) BOOST_CHECK_EQUAL( ptr_tmprcv[i] , ptr_rcvdat[r*nproc+i] );
}
}
////////////////////////////////////////////////////////////////////////////////
BOOST_AUTO_TEST_CASE( broadcast_vector_constant )
{
int i,r;
setup_data_constant();
for (r=0; r<nproc; r++) {
vec_tmprcv.resize(0);
vec_tmprcv.reserve(0);
mpi::PE::instance().broadcast(vec_snddat, vec_tmprcv, r);
for (i=0; i<nproc; i++) BOOST_CHECK_EQUAL( vec_tmprcv[i] , vec_rcvdat[r*nproc+i] );
BOOST_CHECK_EQUAL( (int)vec_tmprcv.size() , rcvcnt );
vec_tmprcv.assign(nproc,0.);
mpi::PE::instance().broadcast(vec_snddat, vec_tmprcv, r);
for (i=0; i<nproc; i++) BOOST_CHECK_EQUAL( vec_tmprcv[i] , vec_rcvdat[r*nproc+i] );
vec_tmprcv=vec_snddat;
mpi::PE::instance().broadcast(vec_tmprcv, vec_tmprcv, r);
for (i=0; i<nproc; i++) BOOST_CHECK_EQUAL( vec_tmprcv[i] , vec_rcvdat[r*nproc+i] );
vec_tmprcvchr.resize(0);
vec_tmprcvchr.reserve(0);
mpi::PE::instance().broadcast(vec_snddatchr, vec_tmprcvchr, r );
BOOST_CHECK_EQUAL( vec_tmprcvchr.size() , sizeof(double)*rcvcnt );
for (i=0; i<nproc; i++) BOOST_CHECK_EQUAL( ((double*)(&vec_tmprcvchr[0]))[i], vec_rcvdat[r*nproc+i] );
for (i=0; i<nproc; i++) ((double*)(&vec_tmprcvchr[0]))[i]=0.;
mpi::PE::instance().broadcast(vec_snddatchr, vec_tmprcvchr, r );
for (i=0; i<nproc; i++) BOOST_CHECK_EQUAL( ((double*)(&vec_tmprcvchr[0]))[i], vec_rcvdat[r*nproc+i] );
vec_tmprcvchr.assign((char*)(ptr_snddat),(char*)(ptr_snddat+nproc));
mpi::PE::instance().broadcast(vec_tmprcvchr, vec_tmprcvchr, r );
for (i=0; i<nproc; i++) BOOST_CHECK_EQUAL( ((double*)(&vec_tmprcvchr[0]))[i], vec_rcvdat[r*nproc+i] );
}
}
////////////////////////////////////////////////////////////////////////////////
BOOST_AUTO_TEST_CASE( broadcast_ptr_variable )
{
int i,j,k,r;
setup_data_variable();
for (r=0; r<nproc; r++) {
delete[] ptr_tmprcv;
ptr_tmprcv=0;
ptr_tmprcv=mpi::PE::instance().broadcast(ptr_snddat, sndcnt, ptr_sndmap, (double*)0, ptr_rcvmap, r);
for (i=0; i<sndcnt; i++) BOOST_CHECK_EQUAL( ptr_tmprcv[i] , ptr_rcvdat[nproc*r+i] );
for (i=0; i<sndcnt; i++) ptr_tmprcv[i]=0.;
mpi::PE::instance().broadcast(ptr_snddat, sndcnt, ptr_sndmap, ptr_tmprcv, ptr_rcvmap, r);
for (i=0; i<sndcnt; i++) BOOST_CHECK_EQUAL( ptr_tmprcv[i] , ptr_rcvdat[nproc*r+i] );
delete[] ptr_tmprcv;
ptr_tmprcv=new double[nproc];
for (i=0; i<nproc; i++) ptr_tmprcv[i]=ptr_snddat[i];
mpi::PE::instance().broadcast(ptr_tmprcv, sndcnt, ptr_sndmap, ptr_tmprcv, ptr_rcvmap, r);
for (i=0; i<sndcnt; i++) BOOST_CHECK_EQUAL( ptr_tmprcv[i] , ptr_rcvdat[nproc*r+i] );
delete[] ptr_tmprcv;
ptr_tmprcv=0;
ptr_tmprcv=(double*)mpi::PE::instance().broadcast((char*)ptr_snddat, sndcnt, ptr_sndmap, (char*)0, ptr_rcvmap, r, sizeof(double));
for (i=0; i<sndcnt; i++) BOOST_CHECK_EQUAL( ptr_tmprcv[i] , ptr_rcvdat[nproc*r+i] );
for (i=0; i<sndcnt; i++) ptr_tmprcv[i]=0.;
mpi::PE::instance().broadcast((char*)ptr_snddat, sndcnt, ptr_sndmap, (char*)ptr_tmprcv, ptr_rcvmap, r, sizeof(double));
for (i=0; i<sndcnt; i++) BOOST_CHECK_EQUAL( ptr_tmprcv[i] , ptr_rcvdat[nproc*r+i] );
delete[] ptr_tmprcv;
ptr_tmprcv=new double[nproc];
for (i=0; i<nproc; i++) ptr_tmprcv[i]=ptr_snddat[i];
mpi::PE::instance().broadcast((char*)ptr_tmprcv, sndcnt, ptr_sndmap, (char*)ptr_tmprcv, ptr_rcvmap, r, sizeof(double));
for (i=0; i<sndcnt; i++) BOOST_CHECK_EQUAL( ptr_tmprcv[i] , ptr_rcvdat[nproc*r+i] );
}
}
////////////////////////////////////////////////////////////////////////////////
BOOST_AUTO_TEST_CASE( broadcast_vector_variable )
{
int i,j,k,r;
setup_data_variable();
for (r=0; r<nproc; r++) {
vec_tmprcv.resize(0);
vec_tmprcv.reserve(0);
mpi::PE::instance().broadcast(vec_snddat, vec_sndmap, vec_tmprcv, vec_rcvmap, r);
for (i=0; i<sndcnt; i++) BOOST_CHECK_EQUAL( vec_tmprcv[i] , vec_rcvdat[nproc*r+i] );
for (i=0; i<sndcnt; i++) vec_tmprcv[i]=0.;
mpi::PE::instance().broadcast(vec_snddat, vec_sndmap, vec_tmprcv, vec_rcvmap, r);
for (i=0; i<sndcnt; i++) BOOST_CHECK_EQUAL( vec_tmprcv[i] , vec_rcvdat[nproc*r+i] );
vec_tmprcv.resize(nproc);
vec_tmprcv.reserve(nproc);
for (i=0; i<nproc; i++) vec_tmprcv[i]=vec_snddat[i];
mpi::PE::instance().broadcast(vec_tmprcv, vec_sndmap, vec_tmprcv, vec_rcvmap, r);
for (i=0; i<sndcnt; i++) BOOST_CHECK_EQUAL( vec_tmprcv[i] , vec_rcvdat[nproc*r+i] );
vec_tmprcvchr.resize(0);
vec_tmprcvchr.reserve(0);
mpi::PE::instance().broadcast(vec_snddatchr, vec_sndmap, vec_tmprcvchr, vec_rcvmap, r, sizeof(double));
for (i=0; i<sndcnt; i++) BOOST_CHECK_EQUAL( ((double*)&vec_tmprcvchr[0])[i] , vec_rcvdat[nproc*r+i] );
for (i=0; i<nproc; i++) ((double*)&vec_tmprcvchr[0])[i]=0.;
mpi::PE::instance().broadcast(vec_snddatchr, vec_sndmap, vec_tmprcvchr, vec_rcvmap, r, sizeof(double));
for (i=0; i<sndcnt; i++) BOOST_CHECK_EQUAL( ((double*)&vec_tmprcvchr[0])[i] , vec_rcvdat[nproc*r+i] );
vec_tmprcvchr.resize(nproc*sizeof(double));
vec_tmprcvchr.reserve(nproc*sizeof(double));
for (i=0; i<nproc; i++) ((double*)(&vec_tmprcvchr[0]))[i]=vec_snddat[i];
mpi::PE::instance().broadcast(vec_tmprcvchr, vec_sndmap, vec_tmprcvchr, vec_rcvmap, r, sizeof(double));
for (i=0; i<sndcnt; i++) BOOST_CHECK_EQUAL( ((double*)&vec_tmprcvchr[0])[i] , vec_rcvdat[nproc*r+i] );
}
}
////////////////////////////////////////////////////////////////////////////////
BOOST_AUTO_TEST_SUITE_END()
////////////////////////////////////////////////////////////////////////////////
| [
"tbanyai@vki.ac.be"
] | tbanyai@vki.ac.be |
6ffb4ce4c71aa6f8c14c27d74c339fde223084aa | 70fe255d0a301952a023be5e1c1fefd062d1e804 | /LeetCode/1309.cpp | 0f54984aa7a45f4a32b3157b30fb9e3843715108 | [
"MIT"
] | permissive | LauZyHou/Algorithm-To-Practice | 524d4318032467a975cf548d0c824098d63cca59 | 66c047fe68409c73a077eae561cf82b081cf8e45 | refs/heads/master | 2021-06-18T01:48:43.378355 | 2021-01-27T14:44:14 | 2021-01-27T14:44:14 | 147,997,740 | 8 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 576 | cpp | class Solution {
public:
string freqAlphabets(string s) {
int len = s.size();
char* ans = new char[len];
int j = 0;
for(int i=0;i<len;) {
if(i==len-1) {
ans[j++] = s[i]-'1'+'a';
break;
}
if(i+2<len && s[i+2]=='#') {
ans[j++] = (s[i]-'0')*10 + s[i+1]-'0' - 10 + 'j';
i += 3;
} else {
ans[j++] = s[i]-'1'+'a';
i++;
}
}
ans[j] = '\0';
return string(ans);
}
}; | [
"java233@foxmail.com"
] | java233@foxmail.com |
9058dc6f40d776c9dbd545db5a2a4cadd00ac1bd | d50135b9c62d39ef89166bd1f5207e9521b1ff5e | /os/components/SIGFOX_Protocol/include/SIGFOX_Protocol.h | 53e0880fd92dd1ea2c86b20f47cf59549d5e0ac4 | [] | no_license | ghsecuritylab/loka_v2_sdk | e0645de3226c63db41c3850e9ed384e335cde9e3 | 68ab76f6c37f59daedc83cd9c90737e42618bd96 | refs/heads/master | 2021-02-28T14:27:25.728525 | 2018-11-13T12:11:34 | 2018-11-13T12:11:34 | 245,704,869 | 0 | 0 | null | 2020-03-07T21:01:03 | 2020-03-07T21:01:02 | null | UTF-8 | C++ | false | false | 2,261 | h | //**********************************************************************************************************************************
// Filename: SIGFOX_Protocol.h
// Date: 18.10.2017
// Author: Rafael Pires
// Company: LOKA SYSTEMS
// Version: 1.0
// Description: Handles data transmission over SIGFOX
//**********************************************************************************************************************************
#ifndef SIGFOX_PROTOCOL_H_
#define SIGFOX_PROTOCOL_H_
//**********************************************************************************************************************************
// Includes Section
//**********************************************************************************************************************************
//**********************************************************************************************************************************
// Define Section
//**********************************************************************************************************************************
//**********************************************************************************************************************************
// Templates Section
//**********************************************************************************************************************************
class SigfoxProtocol{
public:
static void turnOnRadio();
static void turnOffRadio();
static int sendGPIOValue(int gpio, char value, char sendAsDownlink = false);
static int sendAnalogValue(int port, double value, char sendAsDownlink = false);
static int sendAnalogValue(int port, double value, int port2, double value2, char sendAsDownlink = false);
static int sendGPSPosition(double latitude, double longitude, double speed, double timestamp, char sendAsDownlink = false);
static int sendTextLog(char log, char sendAsDownlink = false);
static int sendRawMessage(unsigned char* message, int size, char sendAsDownlink = false, unsigned char* response = NULL);
static int sendAck();
};
#endif
| [
"suppliers@loka-systems.com"
] | suppliers@loka-systems.com |
67f4808beb202ff303d04558173d5dbeb0eab237 | 758378bbd01ff3fc509c5725596c671b53ddb4dd | /demos/Lights/include/GLWindow.h | e26aa07abea68fb19bd571b447b1ee0d0e1cef98 | [] | no_license | suncorner/NGL | 38a5a520899ce4f4a3796e419f5ff3fc35b02721 | 18b232416742f4ccfaecf60c9541559637c9cf5a | refs/heads/master | 2016-09-05T16:51:47.833680 | 2010-06-17T17:58:49 | 2010-06-17T17:58:49 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,101 | h | #ifndef __GL_WINDOW_H__
#define __GL_WINDOW_H__
#include "ngl/Camera.h"
#include "ngl/Colour.h"
#include "ngl/Light.h"
#include "ngl/TransformStack.h"
// must be included after our stuff becuase GLEW needs to be first
#include <QtOpenGL>
class GLWindow : public QGLWidget
{
Q_OBJECT // must include this if you use Qt signals/slots
public :
/// \brief Constructor for GLWindow
/// @param [in] parent the parent window to create the GL context in
GLWindow(
QWidget *_parent
);
~GLWindow();
private :
// used to store the x rotation mouse value
int m_spinXFace;
// used to store the y rotation mouse value
int m_spinYFace;
// flag to indicate if the mouse button is pressed when dragging
bool m_rotate;
// the previous x mouse value
int m_origX;
// the previous y mouse value
int m_origY;
// Our Camera
ngl::Camera *m_cam;
// an array of lights
ngl::Light *m_lightArray[8];
ngl::Real m_teapotRotation;
int m_rotationTimer;
int m_lightChangeTimer;
ngl::TransformStack m_transformStack;
protected:
/// \brief The following methods must be implimented in the sub class
/// this is called when the window is created
/// \note these are part of the Qt API so can't be changed to the coding standard
/// so it can't be called initializeGL )
void initializeGL();
/// \brief this is called whenever the window is re-sized
/// @param[in] _w the width of the resized window
/// @param[in] _h the height of the resized window
/// \note these are part of the Qt API so can't be changed to the coding standard
/// so it can't be called resizeGL )
void resizeGL(
const int _w,
const int _h
);
// \brief this is the main gl drawing routine which is called whenever the window needs to
// be re-drawn
void paintGL();
private :
/// \brief this method is called every time a mouse is moved
/// @param _event the Qt Event structure
/// \note these are part of the Qt API so can't be changed to the coding standard
/// so it can't be called MouseMoveEvent )
void mouseMoveEvent (
QMouseEvent * _event
);
/// \brief this method is called everytime the mouse button is pressed
/// inherited from QObject and overridden here.
/// @param _event the Qt Event structure
/// \note these are part of the Qt API so can't be changed to the coding standard
/// so it can't be called MousePressEvent )
void mousePressEvent (
QMouseEvent *_event
);
// \brief this method is called everytime the mouse button is released
/// inherited from QObject and overridden here.
/// @param _event the Qt Event structure
/// \note these are part of the Qt API so can't be changed to the coding standard
/// so it can't be called MousePressEvent )
void mouseReleaseEvent (
QMouseEvent *_event
);
void CreateLights();
void timerEvent(
QTimerEvent *_event
);
};
#endif
| [
"jmacey@bournemouth.ac.uk"
] | jmacey@bournemouth.ac.uk |
580b5984a2a28eab21b1936034516ce287590abe | be14e50a83bc718d0c871b74eb218188eef5248a | /boost_di/LSP.cpp | a2053948b8154b4b4440e7f7e2d608ae4ee9d41d | [] | no_license | russellboyd/studying | 405a0236affcd02236ef760f7c6aa18bc577870b | 93b30003c7ea513690fc693f21f73a8f42e13690 | refs/heads/master | 2022-04-18T20:42:57.295590 | 2020-03-30T15:49:02 | 2020-03-30T15:49:02 | 113,865,608 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,332 | cpp | //Liskov Substitution Principle
//Objects in a program should be replaceable with instances of their subtypes w/o altering the correctness of the program
#include <vector>
#include <iostream>
#include <string>
class Rectangle
{
protected:
int width, height;
public:
Rectangle(const int width, const int height) : width{width}, height{height}
{
}
virtual int GetWidth() const
{
return width;
}
virtual void SetWidth(const int width)
{
this->width = width;
}
virtual int GetHeight() const
{
return height;
}
virtual void SetHeight(const int heigh)
{
this->height = height;
}
int Area() const {return width * height;}
};
class Square : public Rectangle
{
public:
Square(int size) : Rectangle{size, size} {}
void SetWidth(const int width) override
{
this->width = height = width;
}
void SetHeight(const int height) override
{
this->height = width = height;
}
};
void process(Rectangle& r)
{
int w = r.GetWidth();
r.SetHeight(10);
std::cout << "expect area = " << (w * 10) << ", got " << r.Area() << std::endl;
}
struct RectangleFactory
{
static Rectangle CreateRectangle(int w, int h);
static Rectangle CreateSquare(int size);
};
int main()
{
Rectangle r {5,5};
process(r);
Square s{5};
process(s);
getchar();
return 0;
}
| [
"rgboyd10@gmail.com"
] | rgboyd10@gmail.com |
1c70698993963112634caf2eb68aeffddf86ed1f | 0aac33abf5a943608c7f9d0de70489074f0b49d2 | /distorter.cpp | e2c8011b9d3ffe034eade6b0060c12aae2cffd94 | [] | no_license | edu-ht/Earthbound-Backgrounds | 208f42efc710052a8b27908261c61f5fb41e7c62 | 2e068a7b8ef4401d8699f55c7cc90faf2fa362ab | refs/heads/master | 2020-04-17T01:36:06.899697 | 2019-01-22T20:30:37 | 2019-01-22T20:30:37 | 166,099,048 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,717 | cpp | /*
* Quick-and-dirty battle animation distorter in Allegro
* - Mr. Accident :3
*/
#include <allegro5/allegro.h>
#include <stdio.h>
#include <math.h>
/*
* Function: distort_frame
* Parameters:
* src - the source bitmap
* dst - the bitmap to draw the distortion to
* t - the time value (frame number) to compute
* type - one of: 0 = horizontal, 1 = horizontal interlaced, 2 = vertical
* Notes:
* Source and destination bitmaps must be 32-bit bitmaps, and must not
* be the same bitmap.
*/
void distort_frame(BITMAP* src, BITMAP* dst, int t, int type)
{
ASSERT(source != dest);
ASSERT(source != NULL && dest != NULL);
ASSERT(source->w == dest->w && source->h == dest->h);
ASSERT(type = 0 || type == 1 || type == 3);
// Some hard-coded distortion parameters
float A = 16.0; // Amplitude
float F = 0.1; // Frequency
float S = 0.1; // Time scaling
float C = 1.0; // Compression (only used for vertical distortion)
// Get pointers to raw bitmap data
int* srcdata = (int*)src->line[0];
int* dstdata = (int*)dst->line[0];
int width = src->w;
int height = src->h;
// For each line...
for(int y = 0; y < height; y++)
{
// Calculate the distortion offset for this line
int offset = A * sinf(F * y + S * t);
int src_x = 0; // new x position
int src_y = y; // new y position
if(type == 0)
src_x = offset;
else if(type == 1)
src_x = (y % 2)? offset : -offset;
else if(type == 2)
src_y = y * C + offset;
// Wrap the y offset correctly - e.g., -1 should become height-1
src_y = (src_y + height) % height;
// Copy the line into the destination with translation
for(int x = 0; x < width; x++)
{
// Also need to wrap the x offset
src_x = (src_x + width) % width;
dstdata[y * width + x] = srcdata[src_y * width + src_x];
src_x++;
}
}
}
/*
* Game timer control
*/
volatile int game_time = 0;
void game_timer() {
game_time++;
}
//END_OF_FUNCTION(game_timer)
volatile int fps = 0;
volatile int frame_count = 0;
void fps_timer()
{
fps = frame_count;
frame_count = 0;
}
//END_OF_FUNCTION(fps_timer)
/*
* The entry point of the program
*/
int main(int argc, char** argv)
{
allegro_init();
install_timer();
install_keyboard();
// Set up game timers
install_int_ex(game_timer, BPS_TO_TIMER(60));
install_int_ex(fps_timer, BPS_TO_TIMER(1));
// Set graphics mode
set_color_depth(32);
if(set_gfx_mode(GFX_AUTODETECT_WINDOWED, 512, 512, 0, 0))
{
allegro_message("Failed to set GFX mode.");
return -1;
}
BITMAP* image = load_bitmap("bg.bmp", NULL);
if(!image) {
allegro_message("Failed to create bitmap.");
return -1;
}
// Create distortion buffers and a screen back buffer
BITMAP* dist1 = create_bitmap(image->w, image->h);
BITMAP* dist2 = create_bitmap(image->w, image->h);
BITMAP* dist3 = create_bitmap(image->w, image->h);
BITMAP* back_buffer = create_bitmap(SCREEN_W, SCREEN_H);
// The current frame of distortion
int distort_time = 0;
// Game loop
while(!key[KEY_ESC])
{
while(game_time > 0)
{
// Compute three different distortions from the original image
distort_frame(image, dist1, distort_time, 0);
distort_frame(image, dist2, distort_time, 1);
distort_frame(image, dist3, distort_time, 2);
distort_time++;
game_time--;
}
// Draw all three distortions, plus the original image
blit(image, back_buffer, 0, 0, 0, 0, 256, 256);
blit(dist1, back_buffer, 0, 0, 256, 0, 256, 256);
blit(dist2, back_buffer, 0, 0, 0, 256, 256, 256);
blit(dist3, back_buffer, 0, 0, 256, 256, 256, 256);
// Draw some text with nifty shadows :D
textprintf_ex(back_buffer, font, 1, 1, 0, -1, "Running at %d FPS", fps);
textprintf_ex(back_buffer, font, 0, 0, 0xFFFFFF, -1, "Running at %d FPS", fps);
textout_ex(back_buffer, font, "Original image", 6, 246, 0, -1);
textout_ex(back_buffer, font, "Original image", 5, 245, 0xFFFFFF, -1);
textout_ex(back_buffer, font, "Horizontal", 262, 246, 0, -1);
textout_ex(back_buffer, font, "Horizontal", 261, 245, 0xFFFFFF, -1);
textout_ex(back_buffer, font, "Horizontal interlaced", 6, 502, 0, -1);
textout_ex(back_buffer, font, "Horizontal interlaced", 5, 501, 0xFFFFFF, -1);
textout_ex(back_buffer, font, "Vertical compression", 257, 502, 0, -1);
textout_ex(back_buffer, font, "Vertical compression", 256, 501, 0xFFFFFF, -1);
// Copy the back buffer to the screen
blit(back_buffer, screen, 0, 0, 0, 0, SCREEN_W, SCREEN_H);
// Increment number of frames drawn this second
frame_count++;
}
return 0;
}
//END_OF_MAIN()
| [
"eht17@inf.ufpr.br"
] | eht17@inf.ufpr.br |
41f1f255612ce8a4fca58653506b469f9a5478b5 | 39ad669032a5299a7376c25305e5d2a51455bc37 | /ComIOP/Wrapper/Common/COpcString.h | 09761edd1034111df644f9d693a7130ab8bd0217 | [
"MIT",
"LicenseRef-scancode-generic-cla"
] | permissive | andreasmast/OPC-Client | b52db0eaa23b99e789979169bcde265b00c5ef89 | e1c632c1ed3418961d1a1afc29afe134f8c30402 | refs/heads/master | 2021-01-18T18:25:39.180162 | 2016-06-12T18:13:46 | 2016-06-12T18:13:46 | 60,808,318 | 4 | 2 | null | null | null | null | UTF-8 | C++ | false | false | 7,581 | h | /* ========================================================================
* Copyright (c) 2005-2011 The OPC Foundation, Inc. All rights reserved.
*
* OPC Foundation MIT License 1.00
*
* Permission is hereby granted, free of charge, to any person
* obtaining a copy of this software and associated documentation
* files (the "Software"), to deal in the Software without
* restriction, including without limitation the rights to use,
* copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following
* conditions:
*
* The above copyright notice and this permission notice shall be
* included in all copies or substantial portions of the Software.
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
* OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
* HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
* OTHER DEALINGS IN THE SOFTWARE.
*
* The complete license agreement can be found here:
* http://opcfoundation.org/License/MIT/1.00/
* ======================================================================*/
#ifndef _COpcString_H_
#define _COpcString_H_
#if _MSC_VER >= 1000
#pragma once
#endif // _MSC_VER >= 1000
#include "OpcDefs.h"
#define OPC_EMPTY_STRING _T("")
//==============================================================================
// Class: COpcString
// PURPOSE: Implements a string class.
class OPCUTILS_API COpcString
{
OPC_CLASS_NEW_DELETE_ARRAY();
public:
//==========================================================================
// Operators
// Constructor
COpcString();
COpcString(LPCSTR szStr);
COpcString(LPCWSTR wszStr);
COpcString(const GUID& cGuid);
// Copy Constructor
COpcString(const COpcString& cStr);
// Destructor
~COpcString();
// Cast
operator LPCSTR() const;
operator LPCWSTR() const;
// Assignment
COpcString& operator=(const COpcString& cStr);
// Append
COpcString& operator+=(const COpcString& cStr);
// Index
TCHAR& operator[](UINT uIndex);
TCHAR operator[](UINT uIndex) const;
// Comparison
int Compare(const COpcString& cStr) const;
bool operator==(LPCSTR szStr) const {return (Compare(szStr) == 0);}
bool operator<=(LPCSTR szStr) const {return (Compare(szStr) <= 0);}
bool operator <(LPCSTR szStr) const {return (Compare(szStr) < 0);}
bool operator!=(LPCSTR szStr) const {return (Compare(szStr) != 0);}
bool operator >(LPCSTR szStr) const {return (Compare(szStr) > 0);}
bool operator>=(LPCSTR szStr) const {return (Compare(szStr) >= 0);}
bool operator==(LPCWSTR szStr) const {return (Compare(szStr) == 0);}
bool operator<=(LPCWSTR szStr) const {return (Compare(szStr) <= 0);}
bool operator <(LPCWSTR szStr) const {return (Compare(szStr) < 0);}
bool operator!=(LPCWSTR szStr) const {return (Compare(szStr) != 0);}
bool operator >(LPCWSTR szStr) const {return (Compare(szStr) > 0);}
bool operator>=(LPCWSTR szStr) const {return (Compare(szStr) >= 0);}
bool operator==(const COpcString& szStr) const {return (Compare(szStr) == 0);}
bool operator<=(const COpcString& szStr) const {return (Compare(szStr) <= 0);}
bool operator <(const COpcString& szStr) const {return (Compare(szStr) < 0);}
bool operator!=(const COpcString& szStr) const {return (Compare(szStr) != 0);}
bool operator >(const COpcString& szStr) const {return (Compare(szStr) > 0);}
bool operator>=(const COpcString& szStr) const {return (Compare(szStr) >= 0);}
// Addition
OPCUTILS_API friend COpcString operator+(const COpcString& cStr1, LPCSTR szStr2);
OPCUTILS_API friend COpcString operator+(const COpcString& cStr1, LPCWSTR wszStr2);
OPCUTILS_API friend COpcString operator+(const COpcString& cStr1, const COpcString& cStr2);
OPCUTILS_API friend COpcString operator+(LPCSTR szStr1, const COpcString& cStr2);
OPCUTILS_API friend COpcString operator+(LPCWSTR wszStr1, const COpcString& cStr2);
//==========================================================================
// Public Methods
// GetLength
UINT GetLength() const;
// IsEmpty
bool IsEmpty() const;
// Empty
void Empty() {Free();}
// ToGuid
bool ToGuid(GUID& tGuid) const;
// FromGuid
void FromGuid(const GUID& tGuid);
// GetBuffer
LPTSTR GetBuffer();
// SetBuffer
void SetBuffer(UINT uLength);
// Find
int Find(LPCTSTR tsTarget) const;
// ReverseFind
int ReverseFind(LPCTSTR tsTarget) const;
// SubStr
COpcString SubStr(UINT uStart, UINT uCount = -1) const;
// Trim
COpcString& Trim();
// ToLower
COpcString ToLower(UINT uIndex = -1);
// ToUpper
COpcString ToUpper(UINT uIndex = -1);
// Clone
static LPSTR Clone(LPCSTR szStr);
// Clone
static LPWSTR Clone(LPCWSTR wszStr);
// ToMultiByte
static LPSTR ToMultiByte(LPCWSTR wszStr, int iwszLen = -1);
// ToUnicode
static LPWSTR ToUnicode(LPCSTR szStr, int iszLen = -1);
private:
// TStrBuf
struct TStrBuf
{
UINT uRefs;
LPSTR szStr;
LPWSTR wszStr;
};
//==========================================================================
// Private Methods
// Set
void Set(LPCSTR szStr);
// Set
void Set(LPCWSTR wszStr);
// Set
void Set(const COpcString& cStr);
// Free
void Free();
// Alloc
static TStrBuf* Alloc(UINT uLength);
//==========================================================================
// Private Members
TStrBuf* m_pBuf;
};
//==============================================================================
// FUNCTION: Comparisons
// PURPOSE: Compares two strings.
OPCUTILS_API inline bool operator==(LPCSTR szStr1, const COpcString& cStr2) {return (cStr2.Compare(szStr1) == 0);}
OPCUTILS_API inline bool operator<=(LPCSTR szStr1, const COpcString& cStr2) {return (cStr2.Compare(szStr1) <= 0);}
OPCUTILS_API inline bool operator <(LPCSTR szStr1, const COpcString& cStr2) {return (cStr2.Compare(szStr1) < 0);}
OPCUTILS_API inline bool operator!=(LPCSTR szStr1, const COpcString& cStr2) {return (cStr2.Compare(szStr1) != 0);}
OPCUTILS_API inline bool operator >(LPCSTR szStr1, const COpcString& cStr2) {return (cStr2.Compare(szStr1) > 0);}
OPCUTILS_API inline bool operator>=(LPCSTR szStr1, const COpcString& cStr2) {return (cStr2.Compare(szStr1) >= 0);}
OPCUTILS_API inline bool operator==(LPCWSTR szStr1, const COpcString& cStr2) {return (cStr2.Compare(szStr1) == 0);}
OPCUTILS_API inline bool operator<=(LPCWSTR szStr1, const COpcString& cStr2) {return (cStr2.Compare(szStr1) <= 0);}
OPCUTILS_API inline bool operator <(LPCWSTR szStr1, const COpcString& cStr2) {return (cStr2.Compare(szStr1) < 0);}
OPCUTILS_API inline bool operator!=(LPCWSTR szStr1, const COpcString& cStr2) {return (cStr2.Compare(szStr1) != 0);}
OPCUTILS_API inline bool operator >(LPCWSTR szStr1, const COpcString& cStr2) {return (cStr2.Compare(szStr1) > 0);}
OPCUTILS_API inline bool operator>=(LPCWSTR szStr1, const COpcString& cStr2) {return (cStr2.Compare(szStr1) >= 0);}
#endif // _COpcString_H_
| [
"andreasmast@web.de"
] | andreasmast@web.de |
59a6f34b52f16e1f2817a7b63a20cb1d803eece8 | 508510d10ddcb009fc4fb53a26d897bc462039c0 | /PUBG/SDK/PUBG_GeneralSettingWidget_parameters.hpp | b5fbdc15755bfcf0ca516923d1cf015afb1eebfa | [] | no_license | Avatarchik/PUBG-SDK | ed6e0aa27eac646e557272bbf1607b7351905c8c | 07639ddf96bc0f57fb4b1be0a9b29d5446fcc5da | refs/heads/master | 2021-06-21T07:51:37.309095 | 2017-08-10T08:15:56 | 2017-08-10T08:15:56 | 100,607,141 | 1 | 1 | null | 2017-08-17T13:36:40 | 2017-08-17T13:36:40 | null | UTF-8 | C++ | false | false | 2,547 | hpp | #pragma once
// PLAYERUNKNOWN BattleGrounds () SDK
#ifdef _MSC_VER
#pragma pack(push, 0x8)
#endif
#include "../SDK.hpp"
namespace Classes
{
//---------------------------------------------------------------------------
//Parameters
//---------------------------------------------------------------------------
// Function GeneralSettingWidget.GeneralSettingWidget_C.ApplyMiniMapType
struct UGeneralSettingWidget_C_ApplyMiniMapType_Params
{
};
// Function GeneralSettingWidget.GeneralSettingWidget_C.SettingDefault
struct UGeneralSettingWidget_C_SettingDefault_Params
{
};
// Function GeneralSettingWidget.GeneralSettingWidget_C.IsChanged
struct UGeneralSettingWidget_C_IsChanged_Params
{
bool ReturnValue; // (CPF_Parm, CPF_OutParm, CPF_ZeroConstructor, CPF_ReturnParm, CPF_IsPlainOldData)
};
// Function GeneralSettingWidget.GeneralSettingWidget_C.GetResolutionEnabled
struct UGeneralSettingWidget_C_GetResolutionEnabled_Params
{
bool ReturnValue; // (CPF_Parm, CPF_OutParm, CPF_ZeroConstructor, CPF_ReturnParm, CPF_IsPlainOldData)
};
// Function GeneralSettingWidget.GeneralSettingWidget_C.GetLanguageCultureName
struct UGeneralSettingWidget_C_GetLanguageCultureName_Params
{
struct FString CultureName; // (CPF_Parm, CPF_OutParm, CPF_ZeroConstructor)
};
// Function GeneralSettingWidget.GeneralSettingWidget_C.InitializeResolutionIWidget
struct UGeneralSettingWidget_C_InitializeResolutionIWidget_Params
{
};
// Function GeneralSettingWidget.GeneralSettingWidget_C.Construct
struct UGeneralSettingWidget_C_Construct_Params
{
};
// Function GeneralSettingWidget.GeneralSettingWidget_C.OnApply
struct UGeneralSettingWidget_C_OnApply_Params
{
};
// Function GeneralSettingWidget.GeneralSettingWidget_C.OnDefault
struct UGeneralSettingWidget_C_OnDefault_Params
{
};
// Function GeneralSettingWidget.GeneralSettingWidget_C.OnReset
struct UGeneralSettingWidget_C_OnReset_Params
{
};
// Function GeneralSettingWidget.GeneralSettingWidget_C.ExecuteUbergraph_GeneralSettingWidget
struct UGeneralSettingWidget_C_ExecuteUbergraph_GeneralSettingWidget_Params
{
int EntryPoint; // (CPF_Parm, CPF_ZeroConstructor, CPF_IsPlainOldData)
};
}
#ifdef _MSC_VER
#pragma pack(pop)
#endif
| [
"jl2378@cornell.edu"
] | jl2378@cornell.edu |
e37e0b81bb66490401456e5c354a9ea60a80f482 | b16e2f8cc94df8320f9caf8c8592fa21b1f7c413 | /Codeforces/10D/dp.cpp | c1d96cf7c3fbef73605f2ff0338c9fa9756887c3 | [
"MIT"
] | permissive | codgician/Competitive-Programming | 000dfafea0575b773b0a10502f5128d2088f3398 | 391f3ce9b89b0a4bbbe3ff60eb2369fef57460d4 | refs/heads/master | 2022-06-13T04:59:52.322037 | 2020-04-29T06:38:59 | 2020-04-29T06:38:59 | 104,017,512 | 3 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,451 | cpp | #include <iostream>
#include <cstdio>
#include <algorithm>
#include <cmath>
#include <string>
#include <cstring>
#include <iomanip>
#include <climits>
#include <vector>
#include <queue>
#include <map>
#include <set>
#include <stack>
#include <functional>
#include <iterator>
using namespace std;
#define SIZE 510
int fstArr[SIZE], sndArr[SIZE];
int dp[SIZE], path[SIZE];
void print(int cntPt)
{
if (cntPt == 0)
return;
print(path[cntPt]);
cout << sndArr[cntPt] << " ";
}
int main()
{
ios::sync_with_stdio(false);
int fstLen, sndLen;
cin >> fstLen;
for (int i = 1; i <= fstLen; i++)
{
cin >> fstArr[i];
}
cin >> sndLen;
for (int i = 1; i <= sndLen; i++)
{
cin >> sndArr[i];
}
memset(dp, 0, sizeof(dp));
memset(path, 0, sizeof(path));
for (int i = 1; i <= fstLen; i++)
{
int pos = 0;
for (int j = 1; j <= sndLen; j++)
{
if (fstArr[i] == sndArr[j])
{
dp[j] = dp[pos] + 1;
path[j] = pos;
}
if (fstArr[i] > sndArr[j] && dp[pos] < dp[j])
{
pos = j;
}
}
}
int ans = 0, endPt = 0;
for (int j = 1; j <= sndLen; j++)
{
if (ans < dp[j])
{
ans = dp[j];
endPt = j;
}
}
cout << ans << endl;
print(endPt);
cout << endl;
return 0;
} | [
"codgician@users.noreply.github.com"
] | codgician@users.noreply.github.com |
cf4b4dbd4aa5df35ed2f57b1b668af86d36720c2 | 970dc71a9dea95273c718f3f4cba2d4f81510e9c | /GondarEngine/gsLogger.cpp | 5de0ba23d9e134e2528fa90d5dc3aa7f6360d962 | [] | no_license | ViolaTarek/GondarGameEngine | 4f72794a163ed411ec5a68d48a246c3d6b508d00 | cae7770b885127929724ba94cf37ceede23ac536 | refs/heads/master | 2020-04-05T02:18:59.262339 | 2016-11-01T19:39:18 | 2016-11-01T19:39:18 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 370 | cpp | #include "gsLogger.h"
#include "GLFW\glfw3.h"
#include <iostream>
using namespace std;
void glfwErrorCallback(int error, const char* description)
{
GS_LOG("GLFW Error (Code: " << error << "): " << description);
}
void gsLogger::init() {
glfwSetErrorCallback(glfwErrorCallback);
}
void gsLogger::log(const stringstream& message) {
cout << message.str() << '\n';
} | [
"ygor.reboucas@gmail.com"
] | ygor.reboucas@gmail.com |
9af67073ba90e5b0f15d888764c7a0cd081781af | d327e106285776f28ef1d6c8a7f561b7f05763a6 | /WinStudio/Ex_SDI1/Ex_SDI1.h | 0a1d9b4d2415c0f63a7befb37e1d622fbeb12b3a | [] | no_license | sky94520/old-code | a4bb7b6826906ffa02f57151af2dc21471cf2106 | 6b37cc7a9338d283a330b4afae2c7fbd8aa63683 | refs/heads/master | 2020-05-03T12:37:48.443045 | 2019-07-23T00:38:16 | 2019-07-23T00:38:16 | 178,631,201 | 0 | 0 | null | null | null | null | GB18030 | C++ | false | false | 520 | h |
// Ex_SDI1.h : Ex_SDI1 应用程序的主头文件
//
#pragma once
#ifndef __AFXWIN_H__
#error "在包含此文件之前包含“stdafx.h”以生成 PCH 文件"
#endif
#include "resource.h" // 主符号
// CEx_SDI1App:
// 有关此类的实现,请参阅 Ex_SDI1.cpp
//
class CEx_SDI1App : public CWinAppEx
{
public:
CEx_SDI1App();
// 重写
public:
virtual BOOL InitInstance();
virtual int ExitInstance();
// 实现
afx_msg void OnAppAbout();
DECLARE_MESSAGE_MAP()
};
extern CEx_SDI1App theApp;
| [
"541052067@qq.com"
] | 541052067@qq.com |
a1721387b1facbc3709c20537d8052ed29d3785a | cfeea15c5f9229c9b7f5e1c26311d2bdf727cb8c | /mapping/src/MPS3SeqTools/generateStatsAndCompareAlignerResults.cpp | 3aed3c36ea89e22ff8a425e51de78b9c071324d2 | [] | no_license | turnervo23/MapSplice | c943072c0c0017051bb80b995cf070198817e061 | df36f285cca26b3a77cc2762b2320c9b576bb4cc | refs/heads/master | 2020-05-27T03:24:01.394991 | 2019-06-12T18:10:16 | 2019-06-12T18:10:16 | 188,464,331 | 0 | 0 | null | 2019-05-24T17:43:39 | 2019-05-24T17:43:39 | null | UTF-8 | C++ | false | false | 2,520 | cpp | // This file is a part of MapSplice3. Please refer to LICENSE.TXT for the LICENSE
//incorporate 7 individual programs into one
// for stats of alignments, junctions and compare them with ground truth.
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <malloc.h>
#include <string.h>
#include <iostream>
#include <fstream>
#include <stack>
#include <vector>
#include <hash_map>
#include <map>
#include <set>
//#include <omp.h>
#include "../general/index_info.h"
#include "../general/read_block_test.h"
#include "../general/bwtmap_info.h"
#include "../general/DoubleAnchorScore.h"
#include "../general/sbndm.h"
#include "../general/splice_info.h"
#include "../general/alignInferJunctionHash_info.h"
#include "../general/alignInferJunctionHash_info_vec.h"
using namespace std;
int main(int argc, char** argv)
{
if(argc < 17)
{
cout << "Executable inputIndex outputFolder threadNum dataType('R'or'S') SJ_offset SJ_min_size SJ_max_size " << endl;
cout << "SJsupportNum_max readNum(not pairNum!) readLength_max " << endl;
cout << "inputGroundTruth/Annotation_name inputGroundTruth/Annotation_SJ_file " << endl;
cout << "AlignerName_1 SAM_1 AlignerName_2 SAM_2 (... AlignerName_N, SAM_N)" << endl;
exit(1)
}
string outputFolder = argv[2];
outputFolder += "/";
string log_file_str = outputFolder + "log";
string mkdir = "mkdir -p " + outputFolderStr;
system(mkdir.c_str());
ofstream log_ofs(log_file_str.c_str());
bool realData_simulatedData_bool;
string realData_simulatedData_Str = argv[4];
if(realData_simulatedData_Str == "R")
realData_simulatedData_bool = true;
else if(realData_simulatedData_bool == "S")
realData_simulatedData_bool = false;
else
{
cout << "Please specify the dataType: R for RealData, S for Simulated Data" << endl;
exit(1);
}
string threadNumStr = argv[3];
string offsetStr = argv[5];
string SJ_min_size_str = argv[6];
string SJ_max_size_str = argv[7];
string SJsupportNum_max_str = argv[8];
string readNum_max_str = argv[9];
string readLength_max_str = argv[10];
int threadNum = atoi(threadNumStr.c_str());
int offset = atoi(offsetStr.c_str());
int SJ_min_size = atoi(SJ_min_size_str.c_str());
int SJ_max_size = atoi(SJ_max_size_str.c_str());
int SJsupportNum_max = atoi(SJsupportNum_max_str.c_str());
int readLength_max = atoi(readLength_max_str.c_str());
int readNum_max = atoi(readNum_max_str.c_str());
string groundTruthName = argv[11];
string groundTruthSJfileStr = argv[12];
for(int tmp = 13; tmp < argc; tmp++)
{
}
}
| [
"xli262@g.uky.edu"
] | xli262@g.uky.edu |
c4eb1594e318c8db9d3f10edcdd639050c74a621 | c0c1b2a437ec7ebf243907cc13bd85e62ab5b577 | /chromeos/services/assistant/test_support/fake_libassistant_service.cc | c3a786b9f160ad828a000512b3e5c6c19ef3e518 | [
"BSD-3-Clause"
] | permissive | Xela101/chromium | 06b5d6264dc5440f92af8d73e4e5ea7b53089ad8 | 7e4e583c0cae170b4f9d308250d3aab3e3aa6dd9 | refs/heads/master | 2023-02-27T12:05:10.336834 | 2021-02-02T20:40:26 | 2021-02-02T20:40:26 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,481 | cc | // Copyright 2020 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "chromeos/services/assistant/test_support/fake_libassistant_service.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace chromeos {
namespace assistant {
FakeLibassistantService::FakeLibassistantService() : receiver_(this) {}
FakeLibassistantService::~FakeLibassistantService() = default;
void FakeLibassistantService::Bind(
mojo::PendingReceiver<libassistant::mojom::LibassistantService>
pending_receiver) {
EXPECT_FALSE(receiver_.is_bound())
<< "Cannot bind the LibassistantService twice";
receiver_.Bind(std::move(pending_receiver));
}
void FakeLibassistantService::Unbind() {
receiver_.reset();
service_controller().Unbind();
}
void FakeLibassistantService::Bind(
mojo::PendingReceiver<libassistant::mojom::AudioInputController>
audio_input_controller,
mojo::PendingReceiver<libassistant::mojom::ConversationController>
conversation_controller,
mojo::PendingReceiver<libassistant::mojom::DisplayController>
display_controller,
mojo::PendingReceiver<libassistant::mojom::ServiceController>
service_controller,
mojo::PendingRemote<libassistant::mojom::PlatformDelegate>
platform_delegate) {
service_controller_.Bind(std::move(service_controller));
}
} // namespace assistant
} // namespace chromeos
| [
"chromium-scoped@luci-project-accounts.iam.gserviceaccount.com"
] | chromium-scoped@luci-project-accounts.iam.gserviceaccount.com |
ff81fdd2d1d50fbce580bcb8f7bbd89f3b4410fb | e8372087fd576992670214a91ad8a7855551fb5b | /Projects/3DOpenGLMouseMazeGame/3D_OpenGL_Mouse_Maze_Game/Graphics_MidTerm/ColorCube/LoadBitmap.cpp | 7c457e9ae593546be6aae8dc81a9080b0b5862cc | [] | no_license | braden-catlett/Code-Collection | b8d66c6e137098a3fb7e2ebde346892b704e65d5 | 643700c618225ce96141922d049e5a34628e175d | refs/heads/master | 2022-12-06T00:32:58.645365 | 2020-08-25T22:30:47 | 2020-08-25T22:30:47 | 290,332,207 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,197 | cpp | #include <iostream>
#include <cmath>
#include <iomanip>
#include <cassert>
#include <vector>
#include <cstdio>
using namespace std;
#include <Windows.h>
#include "Angel.h"
#include <GL/glew.h> // for OpenGL extensions
#include <GL/glut.h> // for Glut utility kit
#define GL_CHECK_ERRORS \
{ \
int err=glGetError(); \
if (err!=0) \
{ cout << "OpenGL Error: " << err << endl; \
assert(err == GL_NO_ERROR); \
} \
}
/**********************************************************
*
* VARIABLES DECLARATION
*
*********************************************************/
int num_texture=-1; //Counter to keep track of the last loaded texture
/**********************************************************
*
* FUNCTION MyLoadCubeMapBitmap(char *)
*
* This function loads a bitmap file and return the OpenGL reference ID to use that texture
*
*********************************************************/
int MyLoadCubeMapBitmap(char *filename, GLenum target )
{
int i, j=0; //Index variables
FILE *l_file; //File pointer
unsigned char *l_texture; //The pointer to the memory zone in which we will load the texture
// windows.h gives us these types to work with the Bitmap files
BITMAPFILEHEADER fileheader;
BITMAPINFOHEADER infoheader;
RGBTRIPLE rgb;
num_texture++; // The counter of the current texture is increased
if( (l_file = fopen(filename, "rb"))==NULL) return (-1); // Open the file for reading
fread(&fileheader, sizeof(fileheader), 1, l_file); // Read the fileheader
fseek(l_file, sizeof(fileheader), SEEK_SET); // Jump the fileheader
fread(&infoheader, sizeof(infoheader), 1, l_file); // and read the infoheader
// Now we need to allocate the memory for our image (width * height * color deep)
l_texture = (byte *) malloc(infoheader.biWidth * infoheader.biHeight * 4);
// And fill it with zeros
memset(l_texture, 0, infoheader.biWidth * infoheader.biHeight * 4);
// At this point we can read every pixel of the image
for (i=0; i < infoheader.biWidth*infoheader.biHeight; i++)
{
// We load an RGB value from the file
fread(&rgb, sizeof(rgb), 1, l_file);
// And store it
l_texture[j+0] = rgb.rgbtRed; // Red component
l_texture[j+1] = rgb.rgbtGreen; // Green component
l_texture[j+2] = rgb.rgbtBlue; // Blue component
l_texture[j+3] = 255; // Alpha value
j += 4; // Go to the next position
}
fclose(l_file); // Closes the file stream
GLuint error = glGetError();
//glBindTexture(GL_TEXTURE_CUBE_MAP, num_texture); // Bind the ID texture specified by the 2nd parameter
//GL_CHECK_ERRORS
// The next commands sets the texture parameters
/// glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_WRAP_S, GL_REPEAT); // If the u,v coordinates overflow the range 0,1 the image is repeated
///glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_WRAP_T, GL_REPEAT);
/// glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MAG_FILTER, GL_LINEAR); // The magnification function ("linear" produces better results)
/// glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_NEAREST); //The minifying function
//glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_WRAP_S, GL_REPEAT);
//glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_WRAP_T, GL_REPEAT);
//glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
//glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
GL_CHECK_ERRORS
glTexImage2D( target , 0, GL_RGBA, infoheader.biWidth, infoheader.biHeight, 0, GL_RGBA, GL_UNSIGNED_BYTE, l_texture);
GL_CHECK_ERRORS
///glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_BASE_LEVEL, 0);
///glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MAX_LEVEL, 4);
// And create 2d mipmaps for the minifying function
//gluBuild2DMipmaps(GL_TEXTURE_2D, 4, infoheader.biWidth, infoheader.biHeight, GL_RGBA, GL_UNSIGNED_BYTE, l_texture);
///glGenerateMipmap(GL_TEXTURE_CUBE_MAP);
GL_CHECK_ERRORS
free(l_texture); // Free the memory we used to load the texture
return (num_texture); // Returns the current texture OpenGL ID
} | [
"braden.catlett@gmail.com"
] | braden.catlett@gmail.com |
26b96ba2b2863752eb17b47809625c1b0b991770 | 6e1e553470e6ec9fb76678f50f7e09dd7694c071 | /src/fakmenu.h | 25fe22cdcbc2945e985ef00bf829d28d8d502e70 | [] | no_license | fakob/MoviePrint_v003 | fedfe6b2b8c1598f5ffdddddada8f3d264a0b12b | 55155b34afe4178a3dedab3f5ad01c0f3e7a78e1 | refs/heads/master | 2021-01-20T20:14:35.557797 | 2016-08-07T15:12:57 | 2016-08-07T15:12:57 | 65,137,995 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 12,808 | h |
//
// fakMenu.h
// MoviePrint
//
// Created by fakob on 14/02/21.
//
//
#ifndef FAKMENU_H
#define FAKMENU_H
#include "ofMain.h"
#include "ofxEasing.h"
//#include "ofxTween.h"
//#include "ofxUI.h"
#define FAK_ORANGECOLOR ofColor(238, 71, 0, 255)
#define FAK_DARKORANGECOLOR ofColor(99, 30, 0, 255)
#define FAK_DARKDARKORANGECOLOR ofColor(75, 21, 0, 255)
#define FAK_MIDDLEDARKORANGECOLOR ofColor(170, 50, 0, 255)
#define FAK_LIGHTERMIDDLEDARKORANGECOLOR ofColor(185, 55, 0, 255)
#define FAK_ORANGE1 ofColor(255, 80, 6, 255)
#define FAK_ORANGE2 ofColor(255, 183, 153, 255)
#define FAK_ORANGE3 ofColor(255, 147, 101, 255)
#define FAK_ORANGE4 ofColor(255, 168, 131, 255)
#define FAK_ORANGE5 ofColor(255, 211, 193, 255)
#define FAK_WHITE ofColor(255, 255, 255, 255)
#define FAK_BLACK ofColor(0, 0, 0, 255)
#define FAK_SHADOW ofColor(0, 0, 0, 130)
#define FAK_GRAY ofColor(59, 59, 59, 255)
#define FAK_GREENCOLOR ofColor(117, 130, 16, 255)
#define FAK_LIGHTGRAY ofColor(205, 205, 205, 255)
#define FAK_MIDDLEGRAY ofColor(195, 195, 195, 255)
class fakMenu{
public:
fakMenu(){
}
// functions
void setupMenu(int _ID, float _mMenuX, float _mMenuY, float _mMenuWidth, float _mMenuHeight, float _mMenuRollOverDimension, bool _mButtonActive, char _mLocationOfMenu, bool _mNoBackground){
mMenuX = _mMenuX;
mMenuY = _mMenuY;
mMenuWidth = _mMenuWidth;
mMenuHeight = _mMenuHeight;
mMenuRollOverDimension = _mMenuRollOverDimension;
// tweenMenuInOut.setParameters(1,easingexpo,ofxTween::easeInOut,1.0,0.0,ofRandom(600, 1000),ofRandom(0, 300));
tweenMenuInOut.initialTime = ofGetElapsedTimef() + ofRandom(0, 0.3);
tweenMenuInOut.duration = ofRandom(0.6, 1.0);
tweenMenuInOut.minValue = 1.0;
tweenMenuInOut.maxValue = 0.0;
// tweenMenuInOut2.setParameters(1,easingelastic,ofxTween::easeOut,1.0,0.0,ofRandom(600, 1000),ofRandom(0, 300));
tweenMenuInOut2.initialTime = ofGetElapsedTimef() + ofRandom(0, 0.3);
tweenMenuInOut2.duration = ofRandom(0.6, 1.0);
tweenMenuInOut2.minValue = 1.0;
tweenMenuInOut2.maxValue = 0.0;
mMenuOffsetX = 2;
mMenuOffsetY = 28;
mShadowMargin = 1.5;
mMenuStripeHeight = 8;
mInsideMenuHead = FALSE;
mMenuActive = _mButtonActive;
mLocationOfMenu = _mLocationOfMenu;
mNoBackground = _mNoBackground;
mIsOpenManually = false;
mMenuID = _ID;
switch (mMenuID) {
case 1:
mMenuImage.load("images/MoviePrint_Layout_Menu1_v001_00001.png");
mBackgroundColor = FAK_ORANGE1;
break;
case 4:
mMenuImage.load("images/MoviePrint_Layout_Menu2_v001_00001.png");
mBackgroundColor = FAK_ORANGE4;
break;
case 3:
mMenuImage.load("images/MoviePrint_Layout_Menu3_v001_00001.png");
mBackgroundColor = FAK_ORANGE3;
break;
case 2:
mMenuImage.load("images/MoviePrint_Layout_Menu4_v001_00001.png");
mBackgroundColor = FAK_ORANGE2;
break;
case 5:
mMenuImage.load("images/MoviePrint_Layout_Menu5_v001_00001.png");
mBackgroundColor = FAK_ORANGE5;
break;
case 6:
mMenuImage.load("images/MoviePrint_Layout_Menu6_v001_00001.png");
mBackgroundColor = FAK_ORANGE3;
break;
default:
mBackgroundColor = FAK_GRAY;
break;
}
}
void setTweenIn(){
// tweenMenuInOut.setParameters(1,easingexpo,ofxTween::easeInOut,0.0,1.0,500,0);
tweenMenuInOut.initialTime = ofGetElapsedTimef();
tweenMenuInOut.duration = 0.5;
tweenMenuInOut.minValue = 0.0;
tweenMenuInOut.maxValue = 1.0;
// tweenMenuInOut2.setParameters(1,easingexpo,ofxTween::easeOut,0.0,1.0,300,0);
tweenMenuInOut2.initialTime = ofGetElapsedTimef();
tweenMenuInOut2.duration = 0.3;
tweenMenuInOut2.minValue = 0.0;
tweenMenuInOut2.maxValue = 1.0;
ofNotifyEvent(mMenuIsBeingOpened, mMenuID, this);
}
void setTweenOut(){
// tweenMenuInOut.setParameters(1,easingexpo,ofxTween::easeInOut,1.0,0.0,500,0);
tweenMenuInOut.initialTime = ofGetElapsedTimef();
tweenMenuInOut.duration = 0.5;
tweenMenuInOut.minValue = 1.0;
tweenMenuInOut.maxValue = 0.0;
// tweenMenuInOut2.setParameters(1,easingexpo,ofxTween::easeInOut,1.0,0.0,300,0);
tweenMenuInOut2.initialTime = ofGetElapsedTimef();
tweenMenuInOut2.duration = 0.3;
tweenMenuInOut2.minValue = 1.0;
tweenMenuInOut2.maxValue = 0.0;
ofNotifyEvent(mMenuIsBeingClosed, mMenuID, this);
}
bool insideMenuHead(float _x, float _y ){
float minX = mMenuX;
float maxX = mMenuX + mMenuWidth;
float minY, maxY;
if (mLocationOfMenu == 'T') {
minY = mMenuY;
maxY = mMenuY + mMenuRollOverDimension;
} else if (mLocationOfMenu == 'B') {
minY = mMenuY - mMenuRollOverDimension;
maxY = mMenuY;
} else if (mLocationOfMenu == 'L') {
minX = mMenuX;
maxX = mMenuX + mMenuRollOverDimension;
minY = mMenuY;
maxY = mMenuY + mMenuHeight;
}
return _x >= minX && _x < maxX && _y >= minY && _y < maxY;
}
bool insideMenu(float _x, float _y ){
float minX = mMenuX;
float maxX = mMenuX + mMenuWidth;
float minY, maxY;
if (mLocationOfMenu == 'T') {
minY = mMenuY;
maxY = mMenuY + mMenuHeight;
} else if (mLocationOfMenu == 'B') {
minY = mMenuY - mMenuHeight - mMenuRollOverDimension;
maxY = mMenuY;
} else if (mLocationOfMenu == 'L') {
minX = mMenuX;
maxX = mMenuX + mMenuRollOverDimension + mMenuWidth;
minY = mMenuY;
maxY = mMenuY + mMenuHeight;
}
return _x >= minX && _x < maxX && _y >= minY && _y < maxY;
}
void openMenuManually(){
mIsOpenManually = true;
if (tweenMenuInOut.value != 1.0){
setTweenIn();
}
}
void closeMenuManually(){
mIsOpenManually = false;
if (tweenMenuInOut.value != 0.0){
mInsideMenuHead = false;
setTweenOut();
}
}
void mouseMoved(ofMouseEventArgs & args){
if (mMenuActive) {
if (mInsideMenuHead) {
if (!insideMenu(args.x, args.y)) {
mInsideMenuHead = false;
setTweenOut();
}
} else {
if (insideMenuHead(args.x, args.y)) {
mInsideMenuHead = TRUE;
setTweenIn();
}
}
}
}
void mouseDragged(ofMouseEventArgs & args){
}
void mouseReleased(ofMouseEventArgs & args){
}
void mousePressed(ofMouseEventArgs & args){
if (mInsideMenuHead) {
ofNotifyEvent(mMenuIsBeingClicked, mMenuID, this);
}
}
void mouseScrolled(ofMouseEventArgs & args){
}
void mouseEntered(ofMouseEventArgs & args){
}
void mouseExited(ofMouseEventArgs & args){
}
void registerMouseEvents(){
ofRegisterMouseEvents(this);
}
void unRegisterMouseEvents(){
ofUnregisterMouseEvents(this);
}
void setPosition(float _mMenuX, float _mMenuY){
mMenuX = _mMenuX;
mMenuY = _mMenuY;
}
void setSize(float _mMenuWidth, float _mMenuHeight){
mMenuWidth = _mMenuWidth;
mMenuHeight = _mMenuHeight;
}
float getPositionX(){
return mMenuX;
}
float getPositionY(){
return mMenuY;
}
float getSizeW(){
return mMenuWidth;
}
float getSizeH(){
return mMenuRollOverDimension + (mMenuHeight - mMenuRollOverDimension) * tweenMenuInOut.value;
}
float getRelSizeH(){
return tweenMenuInOut.value;
}
float getRelSizeH2(){
return tweenMenuInOut2.value;
}
void updateMenu(){
tweenMenuInOut.value = ofxeasing::map_clamp(ofGetElapsedTimef(), tweenMenuInOut.initialTime, (tweenMenuInOut.initialTime + tweenMenuInOut.duration), tweenMenuInOut.minValue, tweenMenuInOut.maxValue, &ofxeasing::exp::easeInOut);
tweenMenuInOut2.value = ofxeasing::map_clamp(ofGetElapsedTimef(), tweenMenuInOut2.initialTime, (tweenMenuInOut2.initialTime + tweenMenuInOut2.duration), tweenMenuInOut2.minValue, tweenMenuInOut2.maxValue, &ofxeasing::exp::easeOut);
}
bool getMenuActivated(){
return mInsideMenuHead || mIsOpenManually;
}
void setMenuActive(){
mMenuActive = true;
}
void setMenuInactive(){
closeMenuManually();
mMenuActive = false;
}
bool getInsideMenuHead(){
return mInsideMenuHead;
}
void drawMenu(){
updateMenu();
ofPushMatrix();
ofPushStyle();
if (mLocationOfMenu == 'T') {
ofEnableAlphaBlending();
ofSetColor(FAK_WHITE);
mMenuImage.draw(mMenuX - mMenuOffsetX, mMenuY, mMenuImage.getWidth(), mMenuImage.getHeight());
// ofSetColor(FAK_SHADOW);
// ofRectRounded(mMenuX - mShadowMargin*0.3 + mMenuOffsetX, mMenuY + mMenuOffsetY, mMenuWidth - mMenuOffsetX + mShadowMargin*2, mMenuStripeHeight + mMenuHeight * tweenMenuInOut.value,4.0 * tweenMenuInOut.value);
if (!mNoBackground) {
ofColor tempColor = mBackgroundColor;
ofSetColor(tempColor.lerp(FAK_ORANGE1, tweenMenuInOut.value));
ofDrawRectRounded(mMenuX, mMenuY + mMenuOffsetY, mMenuWidth, mMenuStripeHeight + (mMenuHeight - mMenuOffsetY - mMenuStripeHeight) * tweenMenuInOut.value, 4.0 * tweenMenuInOut.value);
} else {
ofSetColor(mBackgroundColor);
ofDrawRectangle(mMenuX, mMenuY + mMenuOffsetY, mMenuWidth, mMenuStripeHeight);
}
} else if (mLocationOfMenu == 'B') {
ofEnableAlphaBlending();
ofSetColor(FAK_SHADOW);
ofDrawRectangle(mMenuX, mMenuY - (mMenuRollOverDimension + 3.4 + mMenuHeight * tweenMenuInOut.value), mMenuWidth, mMenuRollOverDimension + mMenuHeight * tweenMenuInOut.value);
ofSetColor(mBackgroundColor);
ofDrawRectangle(mMenuX, mMenuY - (mMenuRollOverDimension + mMenuHeight * tweenMenuInOut.value), mMenuWidth, mMenuRollOverDimension + mMenuHeight * tweenMenuInOut.value);
} else if (mLocationOfMenu == 'L') {
ofEnableAlphaBlending();
ofColor tempColor = mBackgroundColor;
// tempColor.set(tempColor.r, tempColor.g, tempColor.b, ((sin(ofGetElapsedTimef()*3)+1.0)/2.0)*200+30); //pulsating
ofSetColor(tempColor.lerp(FAK_ORANGE3, tweenMenuInOut.value));
ofDrawRectangle(mMenuX, mMenuY, mMenuRollOverDimension + mMenuWidth * tweenMenuInOut.value, mMenuHeight);
ofSetColor(255, 255, 255);
mMenuImage.draw(mMenuX - mMenuRollOverDimension/2.0 + mMenuWidth * tweenMenuInOut.value/2.0, mMenuY);
}
ofPopStyle();
ofPopMatrix();
}
// Properties
ofEvent<int> mMenuIsBeingOpened;
ofEvent<int> mMenuIsBeingClosed;
ofEvent<int> mMenuIsBeingClicked;
int mMenuID;
bool mInsideMenuHead;
bool mMenuActive;
char mLocationOfMenu; // 'T' for Top, 'B' for Bottom, 'L' for Left, 'R' for Right
bool mIsOpenManually;
bool mNoBackground;
float mMenuX;
float mMenuY;
float mMenuWidth;
float mMenuHeight;
float mMenuRollOverDimension;
int mMenuOffsetX;
int mMenuOffsetY;
int mMenuStripeHeight; //stripe of menu which is already visible
float mShadowMargin;
ofImage mMenuImage;
ofColor mBackgroundColor;
//--------------------------------------------------------------
struct tweenStruct {
float value;
float initialTime;
float duration;
float minValue;
float maxValue;
};
tweenStruct tweenMenuInOut;
tweenStruct tweenMenuInOut2;
// ofxTween tweenMenuInOut;
// ofxTween tweenMenuInOut2;
// ofxEasingBack easingback;
// ofxEasingBounce easingbounce;
// ofxEasingCirc easingcirc;
// ofxEasingCubic easingcubic;
// ofxEasingElastic easingelastic;
// ofxEasingExpo easingexpo;
// ofxEasingLinear easinglinear;
// ofxEasingQuad easingquad;
// ofxEasingQuart easingquart;
// ofxEasingQuint easingquint;
// ofxEasingSine easingsine;
};
#endif // FAKMENU_H
| [
"jakob@fakob.com"
] | jakob@fakob.com |
16ef5ab7909e9aa672553d8cefb68cb9e58941e5 | aa4889e0964576e315ea44b28620a03a5e2eaf49 | /92 亲和数.cpp | ecd9a6d12431a591a7d5302ac42633720aa6da76 | [] | no_license | TodyStewart/DevC-Files | c7f64fb679b2d24b5c1bb73fbaa45bbb4fe3829d | dce6c9b66592b49ba2332b3485b7e0a3e3bd88ab | refs/heads/main | 2023-05-10T02:28:53.753655 | 2021-06-07T14:13:53 | 2021-06-07T14:13:53 | 374,690,876 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 843 | cpp | #include<bits/stdc++.h>
using namespace std;
long long a,b,x,y,temp1,temp2,tot;
bool prime[100000000];
void luckynumber(long long a,long long b)
{
for(int z=1;z<=b;z++)
prime[z]=true;
prime[1]=false;
for(x=2;x<=sqrt(b);x++)
if(prime[x])
for(y=2;y<=b/x;y++)
prime[x*y]=false;
for(x=a;x<=b;x++)
{
if(x!=temp2&&!prime[x])
{
temp1=1; temp2=1;
for(int i=2;i<=sqrt(x);i++)
if(x%i==0)
{
temp1+=i;
temp1+=(x/i);
}
if(temp1>x&&!prime[temp1])
{
for(int j=2;j<=sqrt(temp1);j++)
if(temp1%j==0)
{
temp2+=j;
temp2+=(temp1/j);
}
if(temp2==x)
tot+=1;
}
}
}
printf("%ld",tot);
}
int main()
{
cin>>a>>b;
luckynumber(a,b);
return 0;
}
| [
"123483705@qq.com"
] | 123483705@qq.com |
c73d89027b71f1273d13d7881237cb3c09840f15 | 38c10c01007624cd2056884f25e0d6ab85442194 | /third_party/WebKit/Source/modules/serviceworkers/RespondWithObserver.cpp | 8eecaab106c2805e763df6896aa5177558fe03e7 | [
"BSD-3-Clause",
"LGPL-2.0-or-later",
"LicenseRef-scancode-warranty-disclaimer",
"LGPL-2.1-only",
"GPL-1.0-or-later",
"GPL-2.0-only",
"LGPL-2.0-only",
"BSD-2-Clause",
"LicenseRef-scancode-other-copyleft",
"MIT",
"Apache-2.0"
] | permissive | zenoalbisser/chromium | 6ecf37b6c030c84f1b26282bc4ef95769c62a9b2 | e71f21b9b4b9b839f5093301974a45545dad2691 | refs/heads/master | 2022-12-25T14:23:18.568575 | 2016-07-14T21:49:52 | 2016-07-23T08:02:51 | 63,980,627 | 0 | 2 | BSD-3-Clause | 2022-12-12T12:43:41 | 2016-07-22T20:14:04 | null | UTF-8 | C++ | false | false | 10,586 | cpp | // Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "config.h"
#include "modules/serviceworkers/RespondWithObserver.h"
#include "bindings/core/v8/ScriptFunction.h"
#include "bindings/core/v8/ScriptPromise.h"
#include "bindings/core/v8/ScriptValue.h"
#include "bindings/core/v8/V8Binding.h"
#include "bindings/modules/v8/V8Response.h"
#include "core/dom/ExceptionCode.h"
#include "core/dom/ExecutionContext.h"
#include "core/inspector/ConsoleMessage.h"
#include "core/streams/Stream.h"
#include "modules/fetch/BodyStreamBuffer.h"
#include "modules/serviceworkers/ServiceWorkerGlobalScopeClient.h"
#include "platform/RuntimeEnabledFeatures.h"
#include "public/platform/modules/serviceworker/WebServiceWorkerResponse.h"
#include "wtf/Assertions.h"
#include "wtf/RefPtr.h"
#include <v8.h>
namespace blink {
namespace {
// Returns the error message to let the developer know about the reason of the unusual failures.
const String getMessageForResponseError(WebServiceWorkerResponseError error, const KURL& requestURL)
{
String errorMessage = "The FetchEvent for \"" + requestURL.string() + "\" resulted in a network error response: ";
switch (error) {
case WebServiceWorkerResponseErrorPromiseRejected:
errorMessage = errorMessage + "the promise was rejected.";
break;
case WebServiceWorkerResponseErrorDefaultPrevented:
errorMessage = errorMessage + "preventDefault() was called without calling respondWith().";
break;
case WebServiceWorkerResponseErrorNoV8Instance:
errorMessage = errorMessage + "an object that was not a Response was passed to respondWith().";
break;
case WebServiceWorkerResponseErrorResponseTypeError:
errorMessage = errorMessage + "the promise was resolved with an error response object.";
break;
case WebServiceWorkerResponseErrorResponseTypeOpaque:
errorMessage = errorMessage + "an \"opaque\" response was used for a request whose type is not no-cors";
break;
case WebServiceWorkerResponseErrorResponseTypeNotBasicOrDefault:
ASSERT_NOT_REACHED();
break;
case WebServiceWorkerResponseErrorBodyUsed:
errorMessage = errorMessage + "a Response whose \"bodyUsed\" is \"true\" cannot be used to respond to a request.";
break;
case WebServiceWorkerResponseErrorResponseTypeOpaqueForClientRequest:
errorMessage = errorMessage + "an \"opaque\" response was used for a client request.";
break;
case WebServiceWorkerResponseErrorResponseTypeOpaqueRedirect:
errorMessage = errorMessage + "an \"opaqueredirect\" type response was used for a request which is not a navigation request.";
break;
case WebServiceWorkerResponseErrorUnknown:
default:
errorMessage = errorMessage + "an unexpected error occurred.";
break;
}
return errorMessage;
}
bool isNavigationRequest(WebURLRequest::FrameType frameType)
{
return frameType != WebURLRequest::FrameTypeNone;
}
bool isClientRequest(WebURLRequest::FrameType frameType, WebURLRequest::RequestContext requestContext)
{
return isNavigationRequest(frameType) || requestContext == WebURLRequest::RequestContextSharedWorker || requestContext == WebURLRequest::RequestContextWorker;
}
class NoopLoaderClient final : public GarbageCollectedFinalized<NoopLoaderClient>, public FetchDataLoader::Client {
WTF_MAKE_NONCOPYABLE(NoopLoaderClient);
USING_GARBAGE_COLLECTED_MIXIN(NoopLoaderClient);
public:
NoopLoaderClient() = default;
void didFetchDataLoadedStream() override {}
void didFetchDataLoadFailed() override {}
DEFINE_INLINE_TRACE() { FetchDataLoader::Client::trace(visitor); }
};
} // namespace
class RespondWithObserver::ThenFunction final : public ScriptFunction {
public:
enum ResolveType {
Fulfilled,
Rejected,
};
static v8::Local<v8::Function> createFunction(ScriptState* scriptState, RespondWithObserver* observer, ResolveType type)
{
ThenFunction* self = new ThenFunction(scriptState, observer, type);
return self->bindToV8Function();
}
DEFINE_INLINE_VIRTUAL_TRACE()
{
visitor->trace(m_observer);
ScriptFunction::trace(visitor);
}
private:
ThenFunction(ScriptState* scriptState, RespondWithObserver* observer, ResolveType type)
: ScriptFunction(scriptState)
, m_observer(observer)
, m_resolveType(type)
{
}
ScriptValue call(ScriptValue value) override
{
ASSERT(m_observer);
ASSERT(m_resolveType == Fulfilled || m_resolveType == Rejected);
if (m_resolveType == Rejected) {
m_observer->responseWasRejected(WebServiceWorkerResponseErrorPromiseRejected);
value = ScriptPromise::reject(value.scriptState(), value).scriptValue();
} else {
m_observer->responseWasFulfilled(value);
}
m_observer = nullptr;
return value;
}
Member<RespondWithObserver> m_observer;
ResolveType m_resolveType;
};
RespondWithObserver* RespondWithObserver::create(ExecutionContext* context, int eventID, const KURL& requestURL, WebURLRequest::FetchRequestMode requestMode, WebURLRequest::FrameType frameType, WebURLRequest::RequestContext requestContext)
{
return new RespondWithObserver(context, eventID, requestURL, requestMode, frameType, requestContext);
}
void RespondWithObserver::contextDestroyed()
{
ContextLifecycleObserver::contextDestroyed();
m_state = Done;
}
void RespondWithObserver::didDispatchEvent(bool defaultPrevented)
{
ASSERT(executionContext());
if (m_state != Initial)
return;
if (defaultPrevented) {
responseWasRejected(WebServiceWorkerResponseErrorDefaultPrevented);
return;
}
ServiceWorkerGlobalScopeClient::from(executionContext())->didHandleFetchEvent(m_eventID);
m_state = Done;
}
void RespondWithObserver::respondWith(ScriptState* scriptState, ScriptPromise scriptPromise, ExceptionState& exceptionState)
{
if (m_state != Initial) {
exceptionState.throwDOMException(InvalidStateError, "The fetch event has already been responded to.");
return;
}
m_state = Pending;
scriptPromise.then(
ThenFunction::createFunction(scriptState, this, ThenFunction::Fulfilled),
ThenFunction::createFunction(scriptState, this, ThenFunction::Rejected));
}
void RespondWithObserver::responseWasRejected(WebServiceWorkerResponseError error)
{
ASSERT(executionContext());
executionContext()->addConsoleMessage(ConsoleMessage::create(JSMessageSource, WarningMessageLevel, getMessageForResponseError(error, m_requestURL)));
// The default value of WebServiceWorkerResponse's status is 0, which maps
// to a network error.
WebServiceWorkerResponse webResponse;
webResponse.setError(error);
ServiceWorkerGlobalScopeClient::from(executionContext())->didHandleFetchEvent(m_eventID, webResponse);
m_state = Done;
}
void RespondWithObserver::responseWasFulfilled(const ScriptValue& value)
{
ASSERT(executionContext());
if (!V8Response::hasInstance(value.v8Value(), toIsolate(executionContext()))) {
responseWasRejected(WebServiceWorkerResponseErrorNoV8Instance);
return;
}
Response* response = V8Response::toImplWithTypeCheck(toIsolate(executionContext()), value.v8Value());
// "If one of the following conditions is true, return a network error:
// - |response|'s type is |error|.
// - |request|'s mode is not |no-cors| and response's type is |opaque|.
// - |request| is a client request and |response|'s type is neither
// |basic| nor |default|."
const FetchResponseData::Type responseType = response->response()->type();
if (responseType == FetchResponseData::ErrorType) {
responseWasRejected(WebServiceWorkerResponseErrorResponseTypeError);
return;
}
if (responseType == FetchResponseData::OpaqueType) {
if (m_requestMode != WebURLRequest::FetchRequestModeNoCORS) {
responseWasRejected(WebServiceWorkerResponseErrorResponseTypeOpaque);
return;
}
// The request mode of client requests should be "same-origin" but it is
// not explicitly stated in the spec yet. So we need to check here.
// FIXME: Set the request mode of client requests to "same-origin" and
// remove this check when the spec will be updated.
// Spec issue: https://github.com/whatwg/fetch/issues/101
if (isClientRequest(m_frameType, m_requestContext)) {
responseWasRejected(WebServiceWorkerResponseErrorResponseTypeOpaqueForClientRequest);
return;
}
}
if (!isNavigationRequest(m_frameType) && responseType == FetchResponseData::OpaqueRedirectType) {
responseWasRejected(WebServiceWorkerResponseErrorResponseTypeOpaqueRedirect);
return;
}
if (response->bodyUsed()) {
responseWasRejected(WebServiceWorkerResponseErrorBodyUsed);
return;
}
response->setBodyPassed();
WebServiceWorkerResponse webResponse;
response->populateWebServiceWorkerResponse(webResponse);
BodyStreamBuffer* buffer = response->internalBodyBuffer();
if (buffer) {
RefPtr<BlobDataHandle> blobDataHandle = buffer->drainAsBlobDataHandle(FetchDataConsumerHandle::Reader::AllowBlobWithInvalidSize);
if (blobDataHandle) {
webResponse.setBlobDataHandle(blobDataHandle);
} else {
Stream* outStream = Stream::create(executionContext(), "");
webResponse.setStreamURL(outStream->url());
buffer->startLoading(executionContext(), FetchDataLoader::createLoaderAsStream(outStream), new NoopLoaderClient);
}
}
ServiceWorkerGlobalScopeClient::from(executionContext())->didHandleFetchEvent(m_eventID, webResponse);
m_state = Done;
}
RespondWithObserver::RespondWithObserver(ExecutionContext* context, int eventID, const KURL& requestURL, WebURLRequest::FetchRequestMode requestMode, WebURLRequest::FrameType frameType, WebURLRequest::RequestContext requestContext)
: ContextLifecycleObserver(context)
, m_eventID(eventID)
, m_requestURL(requestURL)
, m_requestMode(requestMode)
, m_frameType(frameType)
, m_requestContext(requestContext)
, m_state(Initial)
{
}
DEFINE_TRACE(RespondWithObserver)
{
ContextLifecycleObserver::trace(visitor);
}
} // namespace blink
| [
"zeno.albisser@hemispherian.com"
] | zeno.albisser@hemispherian.com |
e4160f6ca14ac43752e98bcf0da1382be7903e90 | d2d4028ee83066400c53b7144ec416bff1fedc83 | /ACM-UVA/458/458.cpp | b966e7fcddd9a505aa2628d9c4095345cdea80f0 | [] | no_license | sergarb1/Competitive-Programming-Solved-Problems | f822e3a11d8977e3bdacbe5e478055af792bdd0e | b33af9d6168a4acaf7f398d5e0598df99686e51a | refs/heads/master | 2023-01-11T15:38:05.933581 | 2022-12-27T12:29:45 | 2022-12-27T12:29:45 | 137,689,428 | 5 | 12 | null | null | null | null | UTF-8 | C++ | false | false | 738 | cpp | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#define MAX_CADENA 2000000
int main()
{
char cadena[MAX_CADENA];
int i,tam;
#ifndef ONLINE_JUDGE
close (0);
open ("458.in", O_RDONLY);
close (1);
open ("458.out", O_WRONLY | O_CREAT, 0600);
#endif
while(!feof(stdin))
{
fgets(cadena,MAX_CADENA,stdin);
tam=strlen(cadena);
if(feof(stdin))
return 0;
for(i=0;i<tam;i++)
{
if(cadena[i]!='\n')
printf("%c",cadena[i]-7);
else
printf("%c",cadena[i]);
}
}
return 0;
}
| [
"sergi.profesor@gmail.com"
] | sergi.profesor@gmail.com |
2d533b365caaaffa8b57b6a94fd7620d7dd10004 | 7d9d300dbb58acd69cbc005a501ff193aadb5801 | /180901.Editor/180901.Editor.cpp | 7fcebede1f96590b7558b71b811d5532e2e690e8 | [] | no_license | jameskim3/_project5 | e2954defce54b1238b077658186857a9b5638f63 | 6ce688063b7c028e5792fd03f79278638374e681 | refs/heads/master | 2023-07-22T23:03:23.432003 | 2021-09-06T13:09:11 | 2021-09-06T13:09:11 | 401,706,722 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,842 | cpp | #include <iostream>
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
static char document[1024 * 1024 + 2];
static int DS;
static int SCORE = 0;
static int PANELTY = 0;
static int seed = 3;
static void verify(char* document);
extern void create();
extern void putChar(char a);
extern void putEnter();
extern void putBackSpace();
extern void moveUp(int n);
extern void moveDown(int n);
extern void moveLeft(int n);
extern void moveRight(int n);
extern void close(char* document);
static int peuso_rand()
{
seed = (214013 * seed + 2531011);
return (seed >> 16) & 32767;
}
int TC = 100;
int main()
{
freopen("in.txt", "r", stdin);
time_t start = clock();
for (register int tc = 0; tc < TC; tc++)
{
create();
DS = 0;
int count = 0;
int char_cnt;
while (DS < 1024*1024 - 1)
{
if (peuso_rand() % 100 == 99)
{
putEnter();
DS++;
}
if (peuso_rand() % 100 == 99)
{
switch (peuso_rand() % 4)
{
case 0: moveUp(peuso_rand() % 100); break;
case 1: moveDown(peuso_rand() % 100); break;
case 2: moveLeft(peuso_rand() % 100); break;
case 3: moveRight(peuso_rand() % 100); break;
}
}
if (peuso_rand() % 100 == 99)
{
if (DS != 0)
{
putBackSpace();
DS--;
}
}
putChar('A' + peuso_rand() % 26);
DS++;
}
close(document);
verify(document);
}
SCORE += (clock() - start) / (CLOCKS_PER_SEC / 1000);
printf("SCORE:%d", SCORE + PANELTY);
}
static void verify(char* document)
{
unsigned long hash = 5381;
for (int i = 0; i < 1024 * 1024 - 1; i++)
{
hash = (((hash << 5) + hash) + document[i]) % 2531011;
}
printf("\n%d", hash);
int ans_val;
scanf("%d", &ans_val);
if (hash != ans_val)
PANELTY += 1000000;
}
/*
1239608 661 111 98 102 69 175 87 3 483 31
1459589 110 33 234 3 6 449 149 13 51 253
256761 96 66 233 1 66 6 46 74 20
*/ | [
"ipofri2@gmail.com"
] | ipofri2@gmail.com |
0fde8cf6bd603eaa6df2e63f7915f0451c6c954f | a1448c6dcc51887ce0cb4679154844c8f1731ed9 | /healthboost.cpp | 58295dc28799be15901dbb78c98a26ebf77e946d | [] | no_license | edwardUL99/CS4076-ZorkUL | 2b0ca100c0ee8ed5caac76d07fa1412431daa19d | 0dc5c8d72b12a33775a275697bc4f4555cfbad46 | refs/heads/master | 2022-07-04T19:29:52.557409 | 2020-05-12T22:16:11 | 2020-05-12T22:16:11 | 263,445,136 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 521 | cpp | #include "healthboost.h"
#include <sstream>
// 9. Initialiser list
HealthBoost::HealthBoost(string description, int boostValue, ZorkUL *game) : Boost(description, boostValue, game) {
}
void HealthBoost::apply() {
Character &player = game->getPlayer();
player.setHealth(player.getHealth() + value);
}
string HealthBoost::getLongDescription() {
stringstream ret;
ret << "Health Boost: " << description;
return ret.str();
}
| [
"18222021@studentmail.ul.ie"
] | 18222021@studentmail.ul.ie |
5f5da5e8f2da4efb51bf24f4a31446ae5f98bcff | c851236c2a3f08f99a1760043080b0a664cf3d92 | /MAXSUMCIRCULARSUBARRAYVVVVIMP.cpp | 48d4e12c88508a0d62f989180cb65f8154a7670f | [] | no_license | Anubhav12345678/competitive-programming | 121ba61645f1edc329edb41515e951b9e510958f | 702cd59a159eafacabc705b218989349572421f9 | refs/heads/master | 2023-01-20T08:12:54.008789 | 2020-11-18T10:23:42 | 2020-11-18T10:23:42 | 313,863,914 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,459 | cpp |
/*
Given a circular array C of integers represented by A, find the maximum possible sum of a non-empty subarray of C.
Here, a circular array means the end of the array connects to the beginning of the array. (Formally, C[i] = A[i] when 0 <= i < A.length, and C[i+A.length] = C[i] when i >= 0.)
Also, a subarray may only include each element of the fixed buffer A at most once. (Formally, for a subarray C[i], C[i+1], ..., C[j], there does not exist i <= k1, k2 <= j with k1 % A.length = k2 % A.length.)
*/
class Solution {
public:
int solve(vector<int> v)
{
int i,j,k,l,n=v.size();
int maxsofar=0,maxtillhere=0;
for(i=0;i<n;i++)
{
maxtillhere+=v[i];
if(maxtillhere<0)
maxtillhere=0;
maxsofar=max(maxsofar,maxtillhere);
}
if(maxsofar==0)
{
sort(v.begin(),v.end());
return v[n-1];
}
return maxsofar;
}
int maxSubarraySumCircular(vector<int>& A) {
int i,j,k,l,n=A.size();
int sum=0;
int ans = solve(A);
for(i=0;i<n;i++)
{
sum+=A[i];
A[i]=-A[i];
}
sum = sum+solve(A);
ans = max(ans,sum);
for(i=0;i<n;i++)
A[i]=-A[i];
if(ans==0)
{
sort(A.begin(),A.end());
return A[n-1];
}
// return max(ans,sum);
return ans;
}
}; | [
"anubhavgupta408@gmail.com"
] | anubhavgupta408@gmail.com |
221a837a59f052b3ce727c15385e40f01a62b8d4 | 7d8c806c571b3cffba198a1d2e02a4d8dd384bf8 | /c++/project/8.0/Manager.cpp | 62bfa11b7085c7fa415aceaf9e8d08f8471851c0 | [] | no_license | qqworker/Cplusplus | a364b75fe950894d3c2373e18bade37b5bf9fe7a | 4742be55b215aca741eb7226b9ff6b42ccd3c4df | refs/heads/master | 2023-04-09T14:19:41.844095 | 2020-12-14T03:39:13 | 2020-12-14T03:39:13 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 467 | cpp | #include "Manager.h"
Manager::Manager(const string& name,double salary,double bonus)
:Employee(name,salary),m_bonus(bonus){
//保存经理的绩效奖金
fprintf(file," %g",m_bonus);
}
void Manager::printExtra(void)const{
cout << "职位:经理" << endl;
cout << "绩效奖金:" << m_bonus << endl;
}
double Manager::calMerit(void){
cout << "请输入绩效因数:";
double factor;
cin >> factor;
return m_bonus * factor;
}
| [
"874319327@qq.com"
] | 874319327@qq.com |
fd6ebd70fdc4d46e7c9bbe4ba4c6ea900ac6e31b | 256262880a2df87b61124ac8dbfd4a868a160127 | /src/Actions/Validate.h | 5734be27ce44f1269351df6a26b549ebcf199e85 | [] | no_license | GamalMohamed/Flowchart-Simulator | b919da3188dc1ea4ff4d4e0104f5654b83c9a909 | ea6e5a2124cb71cbe680f3bb08c8ebfed8acbefd | refs/heads/master | 2021-01-17T06:57:06.739000 | 2016-05-29T10:11:55 | 2016-05-29T10:11:55 | 59,837,913 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 217 | h | #pragma once
#include "Action.h"
class Validate : public Action
{
public:
Validate(ApplicationManager *pAppManager);
virtual void ReadActionParameters();
virtual void Execute();
bool isValid(string& err);
}; | [
"Gamal Mohamed"
] | Gamal Mohamed |
336260bd4e0852394f3d0e8c4c8905437e7e0e32 | 89be3f4867c497e066e3aac86f2f4d1a09269458 | /lib/libarch/arm/ARMFirstTable.cpp | 2280256927736ce7eeeb2105f4610b2552c05001 | [
"Apache-2.0"
] | permissive | SpaceMonkeyClan/FreeNOS-1.0.3 | 90d6320b675ac292c5da785c7193179c6ebd88f9 | 0967dc627a7a73a7ccead427e56ff193dece1248 | refs/heads/main | 2023-08-19T16:12:53.794555 | 2021-10-29T15:30:01 | 2021-10-29T15:30:01 | 404,900,188 | 0 | 1 | Apache-2.0 | 2021-10-18T04:40:38 | 2021-09-09T23:44:19 | C++ | UTF-8 | C++ | false | false | 9,746 | cpp | /*
* Copyright (C) 2015 Niek Linnenbank
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include <FreeNOS/System.h>
#include <SplitAllocator.h>
#include <MemoryBlock.h>
#include "ARMCore.h"
#include "ARMConstant.h"
#include "ARMFirstTable.h"
/**
* @name First Level Entry Types.
*
* @see ARM Architecture Reference Manual, page 731.
*
* @{
*/
#define PAGE1_NONE 0
#define PAGE1_TABLE (1 << 0)
#define PAGE1_SECTION (1 << 1)
/**
* @}
*/
/**
* @name First Level Memory Types
*
* Inner cache: local L1 cache for one core.
* Outer cache: shared L2 cache for a subset of multiple cores.
* Write-Back cache: sync cache data later, let host continue immediately (faster).
* Write-Through cache: sync cache and RAM simulatously (slower).
* Allocate-On-Write: Each write claims a cache entry.
* No-Allocate-On-Write: Write do no claim a cache entry, only write the RAM directly.
*
* @see https://en.wikipedia.org/wiki/Cache_(computing)
* @{
*/
/** Disable all caching */
#define PAGE1_UNCACHED (PAGE1_TEX)
/** Outer and Inner Write-Back. Allocate on write. */
#define PAGE1_CACHE_WRITEBACK (PAGE1_TEX | PAGE1_CACHE | PAGE1_BUFFER)
/** Outer and Inner Write-Through. No allocate on write. */
#define PAGE1_CACHE_WRITETHROUGH (PAGE1_CACHE)
/** Memory Mapped Device (Private) */
#define PAGE1_DEVICE_PRIV ((1 << 13))
/** Memory Mapped Device (Shared) */
#define PAGE1_DEVICE_SHARED (PAGE1_BUFFER)
#define PAGE1_TEX (1 << 12)
#define PAGE1_CACHE (1 << 3)
#define PAGE1_BUFFER (1 << 2)
#define PAGE1_SHARED (1 << 16)
/**
* @}
*/
/**
* @name Access permission flags
* @{
*/
/** No-execution flag */
#define PAGE1_NOEXEC (1 << 4)
/* Read-only flag */
#ifdef ARMV7
#define PAGE1_APX (1 << 15)
#else
#define PAGE1_APX (1 << 9)
#endif
/* User access permissions flag */
#define PAGE1_AP_USER (1 << 11)
/* System access permissions flag */
#define PAGE1_AP_SYS (1 << 10)
/**
* @}
*/
/**
* Entry inside the page directory of a given virtual address.
*
* @param vaddr Virtual Address.
*
* @return Index of the corresponding page directory entry.
*/
#define DIRENTRY(vaddr) \
((vaddr) >> DIRSHIFT)
ARMSecondTable * ARMFirstTable::getSecondTable(Address virt, SplitAllocator *alloc) const
{
u32 entry = m_tables[ DIRENTRY(virt) ];
// Check if the page table is present.
if (!(entry & PAGE1_TABLE))
return ZERO;
else
return (ARMSecondTable *) alloc->toVirtual(entry & PAGEMASK);
}
MemoryContext::Result ARMFirstTable::map(Address virt,
Address phys,
Memory::Access access,
SplitAllocator *alloc)
{
ARMSecondTable *table = getSecondTable(virt, alloc);
Arch::Cache cache;
Allocator::Range allocPhys, allocVirt;
// Check if the page table is present.
if (!table)
{
// Reject if already mapped as a (super)section
if (m_tables[ DIRENTRY(virt) ] & PAGE1_SECTION)
return MemoryContext::AlreadyExists;
// Allocate a new page table
allocPhys.address = 0;
allocPhys.size = sizeof(ARMSecondTable);
allocPhys.alignment = PAGESIZE;
if (alloc->allocate(allocPhys, allocVirt) != Allocator::Success)
return MemoryContext::OutOfMemory;
MemoryBlock::set((void *)allocVirt.address, 0, PAGESIZE);
// Assign to the page directory. Do not assign permission flags (only for direct sections).
m_tables[ DIRENTRY(virt) ] = allocPhys.address | PAGE1_TABLE;
cache.cleanData(&m_tables[DIRENTRY(virt)]);
table = getSecondTable(virt, alloc);
}
return table->map(virt, phys, access);
}
MemoryContext::Result ARMFirstTable::mapLarge(Memory::Range range,
SplitAllocator *alloc)
{
Arch::Cache cache;
if (range.size & 0xfffff)
return MemoryContext::InvalidSize;
if ((range.phys & ~PAGEMASK) || (range.virt & ~PAGEMASK))
return MemoryContext::InvalidAddress;
for (Size i = 0; i < range.size; i += MegaByte(1))
{
if (m_tables[ DIRENTRY(range.virt + i) ] & (PAGE1_TABLE | PAGE1_SECTION))
return MemoryContext::AlreadyExists;
m_tables[ DIRENTRY(range.virt + i) ] = (range.phys + i) | PAGE1_SECTION | flags(range.access);
cache.cleanData(&m_tables[DIRENTRY(range.virt + i)]);
}
return MemoryContext::Success;
}
MemoryContext::Result ARMFirstTable::unmap(Address virt, SplitAllocator *alloc)
{
ARMSecondTable *table = getSecondTable(virt, alloc);
Arch::Cache cache;
if (!table)
{
if (m_tables[DIRENTRY(virt)] & PAGE1_SECTION)
{
m_tables[DIRENTRY(virt)] = PAGE1_NONE;
cache.cleanData(&m_tables[DIRENTRY(virt)]);
return MemoryContext::Success;
}
else
return MemoryContext::InvalidAddress;
}
else
return table->unmap(virt);
}
MemoryContext::Result ARMFirstTable::translate(Address virt,
Address *phys,
SplitAllocator *alloc) const
{
ARMSecondTable *table = getSecondTable(virt, alloc);
if (!table)
{
if (m_tables[DIRENTRY(virt)] & PAGE1_SECTION)
{
const Address offsetInSection = virt % MegaByte(1);
*phys = (m_tables[DIRENTRY(virt)] & SECTIONMASK) +
((offsetInSection / PAGESIZE) * PAGESIZE);
return MemoryContext::Success;
}
return MemoryContext::InvalidAddress;
}
else
return table->translate(virt, phys);
}
MemoryContext::Result ARMFirstTable::access(Address virt,
Memory::Access *access,
SplitAllocator *alloc) const
{
ARMSecondTable *table = getSecondTable(virt, alloc);
if (!table)
return MemoryContext::InvalidAddress;
else
return table->access(virt, access);
}
u32 ARMFirstTable::flags(Memory::Access access) const
{
u32 f = PAGE1_AP_SYS;
// Permissions
if (!(access & Memory::Executable)) f |= PAGE1_NOEXEC;
if ((access & Memory::User)) f |= PAGE1_AP_USER;
if (!(access & Memory::Writable)) f |= PAGE1_APX;
// Caching
if (access & Memory::Device) f |= PAGE1_DEVICE_SHARED;
else if (access & Memory::Uncached) f |= PAGE1_UNCACHED;
else f |= PAGE1_CACHE_WRITEBACK;
return f;
}
inline void ARMFirstTable::releasePhysical(SplitAllocator *alloc,
const Address phys)
{
// Some pages that are part of the boot core's memory region
// are mapped on secondary cores. They can't be released there.
const Address allocBase = alloc->base();
const Size allocSize = alloc->size();
if (phys < allocBase || phys > allocBase + allocSize)
{
return;
}
// Note that some pages may have double mappings.
// Avoid attempting to release the same page twice or more.
if (alloc->isAllocated(phys))
{
alloc->release(phys);
}
}
MemoryContext::Result ARMFirstTable::releaseRange(const Memory::Range range,
SplitAllocator *alloc)
{
Address phys;
// Walk the full range of memory specified
for (Size addr = range.virt; addr < range.virt + range.size; addr += PAGESIZE)
{
ARMSecondTable *table = getSecondTable(addr, alloc);
if (table == ZERO)
{
return MemoryContext::InvalidAddress;
}
if (table->translate(addr, &phys) != MemoryContext::Success)
{
return MemoryContext::InvalidAddress;
}
releasePhysical(alloc, phys);
table->unmap(addr);
}
return MemoryContext::Success;
}
MemoryContext::Result ARMFirstTable::releaseSection(const Memory::Range range,
SplitAllocator *alloc,
const bool tablesOnly)
{
Address phys;
// Input must be aligned to section address
if (range.virt & ~SECTIONMASK)
{
return MemoryContext::InvalidAddress;
}
// Walk the page directory
for (Size addr = range.virt; addr < range.virt + range.size; addr += MegaByte(1))
{
ARMSecondTable *table = getSecondTable(addr, alloc);
if (!table)
{
continue;
}
// Release mapped pages, if requested
if (!tablesOnly)
{
for (Size i = 0; i < MegaByte(1); i += PAGESIZE)
{
if (table->translate(i, &phys) == MemoryContext::Success)
{
releasePhysical(alloc, phys);
}
}
}
// Release page table
alloc->release(m_tables[ DIRENTRY(addr) ] & PAGEMASK);
m_tables[ DIRENTRY(addr) ] = 0;
}
return MemoryContext::Success;
}
| [
"renedena842@gmail.com"
] | renedena842@gmail.com |
d9906edc0364cb67db8efdb6e11a31da21012bc8 | cc0f78b105bc3be5a12362393213fc6a07b5cafd | /HomeworkDatabase.h | 761cbe9bab853fbe52ba71dc480eb8db962ef9a5 | [] | no_license | jcisneros21/homework-database | 9d00366d73d0b5dc587caebcc6e8b31ab13106e7 | f5c87447e2d7c008d8542ade69e73646ef85b4e5 | refs/heads/master | 2016-09-06T19:06:53.347693 | 2015-10-05T00:59:47 | 2015-10-05T00:59:47 | 42,222,362 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 442 | h | #ifndef HomeworkDatabase_H
#define HomeworkDatabase_H
#include <string>
class HomeworkDatabase
{
private:
std::string className;
std::string homework;
int dueDate;
public:
HomeworkDatabase(const std::string className, const std::string homework, int dueDate);
HomeworkDatabase();
std::string getClass();
std::string getHomework();
int getDueDate();
};
#endif
| [
"jcisneros@slu.edu"
] | jcisneros@slu.edu |
4fec3dd6a7c875cf1878d5dd6a6238cdd1b6f7ca | 88ae8695987ada722184307301e221e1ba3cc2fa | /third_party/dawn/src/dawn/native/BuddyAllocator.cpp | 2d7de752b71e8ffc105ce9574c767c3c3aab4319 | [
"Apache-2.0",
"LGPL-2.0-or-later",
"MIT",
"GPL-1.0-or-later",
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | iridium-browser/iridium-browser | 71d9c5ff76e014e6900b825f67389ab0ccd01329 | 5ee297f53dc7f8e70183031cff62f37b0f19d25f | refs/heads/master | 2023-08-03T16:44:16.844552 | 2023-07-20T15:17:00 | 2023-07-23T16:09:30 | 220,016,632 | 341 | 40 | BSD-3-Clause | 2021-08-13T13:54:45 | 2019-11-06T14:32:31 | null | UTF-8 | C++ | false | false | 9,637 | cpp | // Copyright 2019 The Dawn Authors
//
// 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.
#include "dawn/native/BuddyAllocator.h"
#include "dawn/common/Assert.h"
#include "dawn/common/Math.h"
namespace dawn::native {
BuddyAllocator::BuddyAllocator(uint64_t maxSize) : mMaxBlockSize(maxSize) {
ASSERT(IsPowerOfTwo(maxSize));
mFreeLists.resize(Log2(mMaxBlockSize) + 1);
// Insert the level0 free block.
mRoot = new BuddyBlock(maxSize, /*offset*/ 0);
mFreeLists[0] = {mRoot};
}
BuddyAllocator::~BuddyAllocator() {
if (mRoot) {
DeleteBlock(mRoot);
}
}
uint64_t BuddyAllocator::ComputeTotalNumOfFreeBlocksForTesting() const {
return ComputeNumOfFreeBlocks(mRoot);
}
uint64_t BuddyAllocator::ComputeNumOfFreeBlocks(BuddyBlock* block) const {
if (block->mState == BlockState::Free) {
return 1;
} else if (block->mState == BlockState::Split) {
return ComputeNumOfFreeBlocks(block->split.pLeft) +
ComputeNumOfFreeBlocks(block->split.pLeft->pBuddy);
}
return 0;
}
uint32_t BuddyAllocator::ComputeLevelFromBlockSize(uint64_t blockSize) const {
// Every level in the buddy system can be indexed by order-n where n = log2(blockSize).
// However, mFreeList zero-indexed by level.
// For example, blockSize=4 is Level1 if MAX_BLOCK is 8.
return Log2(mMaxBlockSize) - Log2(blockSize);
}
uint64_t BuddyAllocator::GetNextFreeAlignedBlock(size_t allocationBlockLevel,
uint64_t alignment) const {
ASSERT(IsPowerOfTwo(alignment));
// The current level is the level that corresponds to the allocation size. The free list may
// not contain a block at that level until a larger one gets allocated (and splits).
// Continue to go up the tree until such a larger block exists.
//
// Even if the block exists at the level, it cannot be used if it's offset is unaligned.
// When the alignment is also a power-of-two, we simply use the next free block whose size
// is greater than or equal to the alignment value.
//
// After one 8-byte allocation:
//
// Level --------------------------------
// 0 32 | S |
// --------------------------------
// 1 16 | S | F2 | S - split
// -------------------------------- F - free
// 2 8 | Aa | F1 | | A - allocated
// --------------------------------
//
// Allocate(size=8, alignment=8) will be satisfied by using F1.
// Allocate(size=8, alignment=4) will be satified by using F1.
// Allocate(size=8, alignment=16) will be satisified by using F2.
//
for (size_t ii = 0; ii <= allocationBlockLevel; ++ii) {
size_t currLevel = allocationBlockLevel - ii;
BuddyBlock* freeBlock = mFreeLists[currLevel].head;
if (freeBlock && (freeBlock->mOffset % alignment == 0)) {
return currLevel;
}
}
return kInvalidOffset; // No free block exists at any level.
}
// Inserts existing free block into the free-list.
// Called by allocate upon splitting to insert a child block into a free-list.
// Note: Always insert into the head of the free-list. As when a larger free block at a lower
// level was split, there were no smaller free blocks at a higher level to allocate.
void BuddyAllocator::InsertFreeBlock(BuddyBlock* block, size_t level) {
ASSERT(block->mState == BlockState::Free);
// Inserted block is now the front (no prev).
block->free.pPrev = nullptr;
// Old head is now the inserted block's next.
block->free.pNext = mFreeLists[level].head;
// Block already in HEAD position (ex. right child was inserted first).
if (mFreeLists[level].head != nullptr) {
// Old head's previous is the inserted block.
mFreeLists[level].head->free.pPrev = block;
}
mFreeLists[level].head = block;
}
void BuddyAllocator::RemoveFreeBlock(BuddyBlock* block, size_t level) {
ASSERT(block->mState == BlockState::Free);
if (mFreeLists[level].head == block) {
// Block is in HEAD position.
mFreeLists[level].head = mFreeLists[level].head->free.pNext;
} else {
// Block is after HEAD position.
BuddyBlock* pPrev = block->free.pPrev;
BuddyBlock* pNext = block->free.pNext;
ASSERT(pPrev != nullptr);
ASSERT(pPrev->mState == BlockState::Free);
pPrev->free.pNext = pNext;
if (pNext != nullptr) {
ASSERT(pNext->mState == BlockState::Free);
pNext->free.pPrev = pPrev;
}
}
}
uint64_t BuddyAllocator::Allocate(uint64_t allocationSize, uint64_t alignment) {
if (allocationSize == 0 || allocationSize > mMaxBlockSize) {
return kInvalidOffset;
}
// Compute the level
const uint32_t allocationSizeToLevel = ComputeLevelFromBlockSize(allocationSize);
ASSERT(allocationSizeToLevel < mFreeLists.size());
uint64_t currBlockLevel = GetNextFreeAlignedBlock(allocationSizeToLevel, alignment);
// Error when no free blocks exist (allocator is full)
if (currBlockLevel == kInvalidOffset) {
return kInvalidOffset;
}
// Split free blocks level-by-level.
// Terminate when the current block level is equal to the computed level of the requested
// allocation.
BuddyBlock* currBlock = mFreeLists[currBlockLevel].head;
for (; currBlockLevel < allocationSizeToLevel; currBlockLevel++) {
ASSERT(currBlock->mState == BlockState::Free);
// Remove curr block (about to be split).
RemoveFreeBlock(currBlock, currBlockLevel);
// Create two free child blocks (the buddies).
const uint64_t nextLevelSize = currBlock->mSize / 2;
BuddyBlock* leftChildBlock = new BuddyBlock(nextLevelSize, currBlock->mOffset);
BuddyBlock* rightChildBlock =
new BuddyBlock(nextLevelSize, currBlock->mOffset + nextLevelSize);
// Remember the parent to merge these back upon de-allocation.
rightChildBlock->pParent = currBlock;
leftChildBlock->pParent = currBlock;
// Make them buddies.
leftChildBlock->pBuddy = rightChildBlock;
rightChildBlock->pBuddy = leftChildBlock;
// Insert the children back into the free list into the next level.
// The free list does not require a specific order. However, an order is specified as
// it's ideal to allocate lower addresses first by having the leftmost child in HEAD.
InsertFreeBlock(rightChildBlock, currBlockLevel + 1);
InsertFreeBlock(leftChildBlock, currBlockLevel + 1);
// Curr block is now split.
currBlock->mState = BlockState::Split;
currBlock->split.pLeft = leftChildBlock;
// Decend down into the next level.
currBlock = leftChildBlock;
}
// Remove curr block from free-list (now allocated).
RemoveFreeBlock(currBlock, currBlockLevel);
currBlock->mState = BlockState::Allocated;
return currBlock->mOffset;
}
void BuddyAllocator::Deallocate(uint64_t offset) {
BuddyBlock* curr = mRoot;
// TODO(crbug.com/dawn/827): Optimize de-allocation.
// Passing allocationSize directly will avoid the following level-by-level search;
// however, it requires the size information to be stored outside the allocator.
// Search for the free block node that corresponds to the block offset.
size_t currBlockLevel = 0;
while (curr->mState == BlockState::Split) {
if (offset < curr->split.pLeft->pBuddy->mOffset) {
curr = curr->split.pLeft;
} else {
curr = curr->split.pLeft->pBuddy;
}
currBlockLevel++;
}
ASSERT(curr->mState == BlockState::Allocated);
// Ensure the block is at the correct level
ASSERT(currBlockLevel == ComputeLevelFromBlockSize(curr->mSize));
// Mark curr free so we can merge.
curr->mState = BlockState::Free;
// Merge the buddies (LevelN-to-Level0).
while (currBlockLevel > 0 && curr->pBuddy->mState == BlockState::Free) {
// Remove the buddy.
RemoveFreeBlock(curr->pBuddy, currBlockLevel);
BuddyBlock* parent = curr->pParent;
// The buddies were inserted in a specific order but
// could be deleted in any order.
DeleteBlock(curr->pBuddy);
DeleteBlock(curr);
// Parent is now free.
parent->mState = BlockState::Free;
// Ascend up to the next level (parent block).
curr = parent;
currBlockLevel--;
}
InsertFreeBlock(curr, currBlockLevel);
}
// Helper which deletes a block in the tree recursively (post-order).
void BuddyAllocator::DeleteBlock(BuddyBlock* block) {
ASSERT(block != nullptr);
if (block->mState == BlockState::Split) {
// Delete the pair in same order we inserted.
DeleteBlock(block->split.pLeft->pBuddy);
DeleteBlock(block->split.pLeft);
}
delete block;
}
} // namespace dawn::native
| [
"jengelh@inai.de"
] | jengelh@inai.de |
eba84c8a7b7b4d32584b5844687ff2725e5b1b79 | 402c363510a1c55679f3bf613bfae091377f28d9 | /CONTROL_MOTOR.ino | acf676256446d28e8c831e85a5b7e71c9dc7f250 | [] | no_license | PutraArmy/PlantSmartArduino | 055f60533cb508ac9d07a2b595ea60ea698da2b8 | 843c6e4732c2150f08eaafba21fe95844a8ca8de | refs/heads/master | 2022-12-02T01:54:33.769493 | 2020-08-15T01:50:56 | 2020-08-15T01:50:56 | 287,658,512 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 638 | ino | void controlMotor() {
SiramRef = Firebase.getInt(DBPump);
refHumiTanahMin = Firebase.getFloat(DBHumiRefMin);
refHumiTanahMax = Firebase.getFloat(DBHumiRefMax);
controlMotorManual();
contorlMotorOtomatis();
}
void controlMotorManual() {
if (SiramRef == 1) {
digitalWrite(PUMP_PIN, ACTIVE);
stsSiram = 1;
} else {
digitalWrite(PUMP_PIN, NON_ACTIVE);
stsSiram = 0;
}
}
void contorlMotorOtomatis() {
if (humiTanah <= refHumiTanahMin) {
digitalWrite(PUMP_PIN, ACTIVE);
stsSiram = 1;
}
if (humiTanah >= refHumiTanahMax) {
digitalWrite(PUMP_PIN, NON_ACTIVE);
stsSiram = 0;
}
}
| [
"armhy333.mahasiswa.unikom.ac.id"
] | armhy333.mahasiswa.unikom.ac.id |
f0ef9e8cd70c91b929f3918a2623f5dda58148e8 | c78a3b5c83435d2d6c6894bc1620ac14b3656283 | /tango-gl-renderer/include/tango-gl-renderer/frustum.h | b3eedaf473cd1dfc5671ef96ef0be4c37414c58a | [
"MIT",
"Apache-2.0"
] | permissive | atroccoli/tango-examples-c | fa4e1051a305164c473a89b9722f45529bb42d7d | e53123e5c6c11e883c3ff90c0f5d36f8e59d9a4e | refs/heads/master | 2021-01-20T16:34:40.616395 | 2014-11-26T22:00:20 | 2014-11-26T22:00:20 | 27,202,251 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,183 | h | /*
* Copyright 2014 Google Inc. All Rights Reserved.
*
* 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.
*/
#ifndef TANGO_GL_RENDERER_FRUSTUM_H
#define TANGO_GL_RENDERER_FRUSTUM_H
#include "tango-gl-renderer/drawable_object.h"
#include "tango-gl-renderer/gl_util.h"
class Frustum : public DrawableObject {
public:
Frustum();
Frustum(const Frustum& other) = delete;
Frustum& operator=(const Frustum&) = delete;
~Frustum();
void Render(const glm::mat4& projection_mat, const glm::mat4& view_mat) const;
private:
GLuint vertex_buffer_;
GLuint shader_program_;
GLuint attrib_vertices_;
GLuint uniform_mvp_mat_;
};
#endif // TANGO_GL_RENDERER_FRUSTUM_H
| [
"xuguo@google.com"
] | xuguo@google.com |
e275416a0eae9265dcd3c29cad5e8c18531983bf | 0d616b8bd6c4688db70ef6b1523be6fcac87945d | /135/e5_14.cpp | 9802779af4ab77fb98ce362fd5616011e4f5b678 | [] | no_license | JasonWu00/cs-master | 88f1ab0918f395d751c03bb6e394e849d2f8c76e | 41236bce5ed945e70bad6870cf2b71fee0ebc767 | refs/heads/main | 2023-04-30T12:32:01.292636 | 2021-05-20T16:20:35 | 2021-05-20T16:20:35 | 369,269,136 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 280 | cpp | //Modified by: Ze Hong Wu (Jason)
//Email: zehong.wu17@myhunter.cuny.edu
//Date: March 11, 2021
//LHomework E5.14
#include <iostream>
using namespace std;
void sort2(int& a, int&b) {
if (b < a) {
int temp_storage = b;
b = a;
a = temp_storage;
}
}
| [
"jasonwul33t@gmail.com"
] | jasonwul33t@gmail.com |
1af925f2ce28b90be1d1be0e15cd4c62185bf8f5 | bc75dda735072384a43013ee472c4871f0697d62 | /AOJ/user.h | 41f029631bab9c175ca474fa1bc2fdaabef8dc2f | [] | no_license | arrows-1011/Tools | 8b7c97fa9b02ae0b5d40a6ba1e9876987bab8b0e | 5663c922c4e8d2830c89cd2a71a6a515405eadf5 | refs/heads/master | 2020-12-24T07:53:31.835445 | 2016-08-23T12:10:18 | 2016-08-23T12:10:18 | 52,806,252 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,133 | h | #include <iostream>
#include <set>
#include <string>
class User {
private:
std::string id;
std::string name;
std::string affiliation;
std::string solved;
std::set<std::string> solved_list;
public:
User();
User(std::string, std::string,
std::string, std::string,
std::set<std::string>);
bool operator < (const User &) const;
void setID(std::string);
std::string getID(void);
void setName(std::string);
std::string getName(void);
void setAffiliation(std::string);
std::string getAffiliation(void);
void setSolved(std::string);
std::string getSolved(void);
void setSolvedList(std::set<std::string>);
std::set<std::string> getSolvedList(void);
void displayInfo(void);
};
extern User parse4User(std::string);
extern User userSearchAPI(std::string);
extern std::set<User> parse4Users(std::string);
extern std::set<User> allUserListSearchAPI(std::string, std::string, std::string, std::string);
extern double differenceProblems(User, User);
extern std::set<User> getSimilarUsers(User);
extern std::string query (std::string);
| [
"s1210207@gmail.com"
] | s1210207@gmail.com |
55b2e028b8617371d369c0ef65672ff6c3da19bd | 29e48649e4e8e9e58b29953ec63e3b3d1ef05dbf | /mapLab/mapLab/Map.h | 76783a71992cf311a64f39944be2efad3e8b32f5 | [] | no_license | karolynalvarez/MapLab | d2eaedd55ec4c0b96261ee98a84496377d4ced68 | ba046d74d83ec6095b130eb424e11341be7bfb14 | refs/heads/master | 2020-05-24T09:52:23.278522 | 2017-03-13T17:14:10 | 2017-03-13T17:14:10 | 84,845,104 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 154 | h | #pragma once
#include "Location.h"
class Map
{
public:
Map(std::string startingLocationName);
~Map();
Location *_currentLocation = nullptr;
};
| [
"ncc"
] | ncc |
bb761d784ce4e5d3b4fc3f8f79a988e8f278cec6 | 0b9cbe14237343a4fdd9077ab9ad506ff73008e9 | /Utils/Scripter/main.cpp | b1d39b83280f5d78a8df9ddae2423f6403072381 | [] | no_license | aicreed/SBSPSS | 9cdfa219f67875db2f971142277732c00955abb8 | 6782909006153f2cba8d80d8e9339ee5fc39d71c | refs/heads/master | 2021-01-04T13:36:22.014724 | 2020-03-06T14:37:45 | 2020-03-06T14:37:45 | 240,575,228 | 0 | 0 | null | 2020-02-14T18:36:51 | 2020-02-14T18:36:50 | null | UTF-8 | C++ | false | false | 1,980 | cpp | /*=========================================================================
main.cpp
Author: PKG
Created:
Project: Spongebob
Purpose:
Copyright (c) 2000 Climax Development Ltd
===========================================================================*/
/*----------------------------------------------------------------------
Includes
-------- */
#include "main.h"
#ifndef _LEXER_H
#include "lexer.h"
#endif
#ifndef __CODEGEN_H__
#include "codegen.h"
#endif
/* Std Lib
------- */
#include <yacc.h>
/* Data
---- */
/*----------------------------------------------------------------------
Tyepdefs && Defines
------------------- */
/*----------------------------------------------------------------------
Structure defintions
-------------------- */
/*----------------------------------------------------------------------
Function Prototypes
------------------- */
/*----------------------------------------------------------------------
Vars
---- */
/*----------------------------------------------------------------------
Function:
Purpose:
Params:
Returns:
---------------------------------------------------------------------- */
extern int main(int argc, char *argv[])
{
int ret;
if(argc!=3)
{
printf("Script compiler thingy\n");
printf("Usage: yl infile outfile\n");
printf("So there..\n\n");
ret=-1;
}
else
{
char *infile;
char *outfile;
infile=argv[1];
outfile=argv[2];
printf("Scripter attempting to compile %s..\n",infile);
if(parseFile(infile,s_baseTreeNode)==YYEXIT_SUCCESS&&s_baseTreeNode)
{
if(openOutputFile(outfile))
{
int byteCount;
byteCount=s_baseTreeNode->generateCode(true);
closeOutputFile();
printf("Generated %d bytes of code in %s\n",byteCount*2,outfile);
ret=0;
}
else
{
ret=-1;
}
}
else
{
ret=-1;
}
}
printf("\n");
return ret;
}
/*===========================================================================
end */
| [
"paul@localhost"
] | paul@localhost |
064af13becaff08e3ecfc1095a35352001a4360b | e74fe677468f44c1109af6798dc10ec1c160e71c | /demo1v1/demo1v1/CFullSceenStatic.cpp | 99c3230933bc7b667c54dc033be168c1a9ae1977 | [] | no_license | shinevv/shinevvSdkWin | e2ecf0a380b6f81e7941ec751af7060402dc6375 | 22ceff02126762cef2939f1e921ba1ca238e4da6 | refs/heads/master | 2021-04-26T23:59:17.926120 | 2019-09-18T04:03:43 | 2019-09-18T04:03:43 | 123,889,236 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,223 | cpp | // CFullSceenStatic.cpp: 实现文件
//
#include "stdafx.h"
#include "CFullSceenStatic.h"
#include "demoDlg.h"
// CFullSceenStatic
IMPLEMENT_DYNAMIC(CFullSceenStatic, CStatic)
CFullSceenStatic::CFullSceenStatic()
{
m_preWinRect = { 0 };
m_bFullScreen = FALSE;
m_hParent = NULL;
m_pParentDlg = NULL;
m_strMemberId = _T("");
}
CFullSceenStatic::~CFullSceenStatic()
{
}
BEGIN_MESSAGE_MAP(CFullSceenStatic, CStatic)
ON_WM_LBUTTONDBLCLK()
END_MESSAGE_MAP()
// CFullSceenStatic 消息处理程序
afx_msg void CFullSceenStatic::OnLButtonDblClk(UINT nFlags, CPoint point)
{
ChangeWindowSize();
}
void CFullSceenStatic::ChangeWindowSize() {
if (!m_bFullScreen)
{
m_hParent = ::GetParent(GetSafeHwnd());
LONG style = ::GetWindowLong(GetSafeHwnd(), GWL_STYLE);
style &= ~WS_CHILD;
style |= WS_POPUP;
::SetWindowLong(GetSafeHwnd(), GWL_STYLE, style);
int nW = GetSystemMetrics(SM_CXSCREEN);
int nH = GetSystemMetrics(SM_CYSCREEN);
::SetParent(GetSafeHwnd(), ::GetDesktopWindow());
::GetWindowRect(GetSafeHwnd(), &m_preWinRect);
::MoveWindow(GetSafeHwnd(), 0, 0, nW, nH, TRUE);
m_bFullScreen = TRUE;
}
else
{
int nW = m_preWinRect.right - m_preWinRect.left;
int nH = m_preWinRect.bottom - m_preWinRect.top;
int nX = m_preWinRect.left;
int nY = m_preWinRect.top;
LONG style = ::GetWindowLong(GetSafeHwnd(), GWL_STYLE);
style |= WS_CHILD;
style &= ~WS_POPUP;
::SetWindowLong(GetSafeHwnd(), GWL_STYLE, style);
::SetParent(GetSafeHwnd(), m_hParent);
::MoveWindow(GetSafeHwnd(), nX, nY, nW, nH, TRUE);
m_bFullScreen = FALSE;
}
if (m_pParentDlg) {
::PostMessage(((CdemoDlg*)m_pParentDlg)->GetSafeHwnd(), WM_FULLSCREEN_REFRESH, NULL, (LPARAM)&m_strMemberId);
}
}
void CFullSceenStatic::SetParentDlg(void* pParentDlg) {
m_pParentDlg = pParentDlg;
}
void CFullSceenStatic::SetMemberId(std::string strMemberId) {
m_strMemberId = strMemberId.c_str();
}
BOOL CFullSceenStatic::PreTranslateMessage(MSG* pMsg) {
if (m_bFullScreen && pMsg->message == WM_KEYDOWN && pMsg->wParam == VK_ESCAPE) {
ChangeWindowSize();
return TRUE;
}
else {
return CStatic::PreTranslateMessage(pMsg);
}
}
| [
"wuqiang@imssys.cn"
] | wuqiang@imssys.cn |
4db67cd3d0bfab33045f0526d2c22cff9eb8dcdb | d61d05748a59a1a73bbf3c39dd2c1a52d649d6e3 | /chromium/device/gamepad/nintendo_controller.h | 356187d1f54c607424e693d7b4c1f7c97517d191 | [
"BSD-3-Clause"
] | permissive | Csineneo/Vivaldi | 4eaad20fc0ff306ca60b400cd5fad930a9082087 | d92465f71fb8e4345e27bd889532339204b26f1e | refs/heads/master | 2022-11-23T17:11:50.714160 | 2019-05-25T11:45:11 | 2019-05-25T11:45:11 | 144,489,531 | 5 | 4 | BSD-3-Clause | 2022-11-04T05:55:33 | 2018-08-12T18:04:37 | null | UTF-8 | C++ | false | false | 7,094 | h | // Copyright 2019 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef DEVICE_GAMEPAD_NINTENDO_CONTROLLER_H_
#define DEVICE_GAMEPAD_NINTENDO_CONTROLLER_H_
#include "device/gamepad/abstract_haptic_gamepad.h"
#include "device/gamepad/gamepad_standard_mappings.h"
#include "services/device/public/mojom/hid.mojom.h"
namespace device {
// NintendoController represents a gaming input for a Nintendo console. In some
// cases, multiple discrete devices can be associated to form one logical
// input. A single NintendoController instance may represent a discrete device,
// or may represent two devices associated to form a composite input. (For
// instance, a pair of matched Joy-Cons may be treated as a single gamepad.)
//
// Switch devices must be initialized in order to provide a good experience.
// Devices that connect over Bluetooth (Joy-Cons and the Pro Controller) default
// to a HID interface that exposes only partial functionality. Devices that
// connect over USB (Pro Controller and Charging Grip) send no controller data
// reports until the initialization sequence is started. In both cases,
// initialization is necessary in order to configure device LEDs, enable and
// disable device features, and fetch calibration data.
//
// After initialization, the Joy-Con or Pro Controller should be in the
// following state:
// * Faster baud rate, if connected over USB.
// * Player indicator light 1 is lit, others are unlit.
// * Home light is 100% on.
// * Accelerometer and gyroscope inputs are enabled with default sensitivity.
// * Vibration is enabled.
// * NFC is disabled.
// * Configured to send controller data reports with report ID 0x30.
//
// Joy-Cons and the Pro Controller provide uncalibrated joystick input. The
// devices store factory calibration data for scaling the joystick axes and
// applying deadzones.
//
// Dual-rumble vibration effects are supported for both discrete devices and for
// composite devices. Joy-Cons and the Pro Controller use linear resonant
// actuators (LRAs) instead of the traditional eccentric rotating mass (ERM)
// vibration actuators. The LRAs are controlled using frequency and amplitude
// pairs rather than a single magnitude value. To simulate a dual-rumble effect,
// the left and right LRAs are set to vibrate at different frequencies as though
// they were the strong and weak ERM actuators. The amplitudes are set to the
// strong and weak effect magnitudes. When a vibration effect is played on a
// composite device, the effect is split so that each component receives one
// channel of the dual-rumble effect.
class NintendoController : public AbstractHapticGamepad {
public:
~NintendoController() override;
// Create a NintendoController for a newly-connected HID device.
static std::unique_ptr<NintendoController> Create(
int source_id,
mojom::HidDeviceInfoPtr device_info,
mojom::HidManager* hid_manager);
// Create a composite NintendoController from two already-connected HID
// devices.
static std::unique_ptr<NintendoController> CreateComposite(
int source_id,
std::unique_ptr<NintendoController> composite1,
std::unique_ptr<NintendoController> composite2,
mojom::HidManager* hid_manager);
// Return true if |vendor_id| and |product_id| describe a Nintendo controller.
static bool IsNintendoController(uint16_t vendor_id, uint16_t product_id);
// Decompose a composite device and return a vector of its subcomponents.
// Return an empty vector if the device is non-composite.
std::vector<std::unique_ptr<NintendoController>> Decompose();
// Begin the initialization sequence. When the device is ready to report
// controller data, |device_ready_closure| is called.
void Open(base::OnceClosure device_ready_closure);
// Return true if the device has completed initialization and is ready to
// report controller data.
bool IsOpen() const { return false; }
// Return true if the device is ready to be assigned a gamepad slot.
bool IsUsable() const;
// Return true if the device is composed of multiple subdevices.
bool IsComposite() const { return is_composite_; }
// Return the source ID assigned to this device.
int GetSourceId() const { return source_id_; }
// Return the bus type for this controller.
GamepadBusType GetBusType() const { return bus_type_; }
// Return the mapping function for this controller.
GamepadStandardMappingFunction GetMappingFunction() const;
// Return true if |guid| is the device GUID for any of the HID devices
// opened for this controller.
bool HasGuid(const std::string& guid) const;
// Perform one-time initialization for the gamepad data in |pad|.
void InitializeGamepadState(bool has_standard_mapping, Gamepad& pad) const;
// Update the button and axis state in |pad|.
void UpdateGamepadState(Gamepad& pad) const;
// Return the handedness of the device, or GamepadHand::kNone if the device
// is not intended to be used in a specific hand.
GamepadHand GetGamepadHand() const;
// AbstractHapticGamepad implementation.
void DoShutdown() override;
void SetVibration(double strong_magnitude, double weak_magnitude) override;
NintendoController(int source_id,
mojom::HidDeviceInfoPtr device_info,
mojom::HidManager* hid_manager);
NintendoController(int source_id,
std::unique_ptr<NintendoController> composite1,
std::unique_ptr<NintendoController> composite2,
mojom::HidManager* hid_manager);
private:
// Initiate a connection request to the HID device.
void Connect(mojom::HidManager::ConnectCallback callback);
// Completion callback for the HID connection request.
void OnConnect(mojom::HidConnectionPtr connection);
// Initiate the sequence of exchanges to prepare the device to provide
// controller data.
void StartInitSequence();
// An ID value to identify this device among other devices enumerated by the
// data fetcher.
const int source_id_;
// The bus type for the underlying HID device.
GamepadBusType bus_type_ = GAMEPAD_BUS_UNKNOWN;
// A composite device contains up to two Joy-Cons as sub-devices.
bool is_composite_ = false;
// Left and right sub-devices for a composite device.
std::unique_ptr<NintendoController> composite_left_;
std::unique_ptr<NintendoController> composite_right_;
// The most recent gamepad state.
Gamepad pad_;
// Information about the underlying HID device.
mojom::HidDeviceInfoPtr device_info_;
// HID service manager.
mojom::HidManager* const hid_manager_;
// The open connection to the underlying HID device.
mojom::HidConnectionPtr connection_;
// A closure, provided in the call to Open, to be called once the device
// becomes ready.
base::OnceClosure device_ready_closure_;
base::WeakPtrFactory<NintendoController> weak_factory_;
};
} // namespace device
#endif // DEVICE_GAMEPAD_NINTENDO_CONTROLLER_H_
| [
"csineneo@gmail.com"
] | csineneo@gmail.com |
761a3fc118fef057f3d8665e752a8e3c13e59616 | 57444ae1f4341b295120a3b14a72fc60397c423a | /FONCTIONS/events/global_events/feedback/ev_wrong_action.cpp | 45559ba097ab16fe1f4e0e7250319e847c207c8c | [] | no_license | PoulpePalpitant/Wall-in | b3c68b463376887d5ee0534cbfb4d6aafa1e2c9c | d3cb6511df1d74c06e800342afa7a994bd9fcff5 | refs/heads/master | 2023-04-09T13:04:43.299234 | 2021-04-16T22:03:54 | 2021-04-16T22:03:54 | 260,096,762 | 3 | 0 | null | null | null | null | ISO-8859-1 | C++ | false | false | 837 | cpp |
#include "ev_wrong_action.h"
#include "../../../UI/console_output/render_list.h"
#include "../../events.h"
#include "../../../player/player.h"
void Ev_Wrong_Action(); // Fait flasher le joueur en rose quand il fait dequoi de pas correct. Ex: tirer quand il peut pas, se déplacer à un endroit blocké ()
static Event ev_WrongAction(Ev_Wrong_Action,2); // Def //
void Ev_Wrong_Action()
{
if (!ev_WrongAction.Is_Active())
{
ConsoleRender::Add_Char(P1.Get_XY(), P1.Get_Sym(), LIGHT_PURPLE);
ev_WrongAction.Activate();
ev_WrongAction.Start(12000);
}
else
{
while (ev_WrongAction.delay.Tick())
{
P1.Dr_Player();
ev_WrongAction.Cancel();
}
}
}
void Ev_Wrong_Action_Add() // Cancel et et réinitialise l'event() s'il est actif
{
if (ev_WrongAction.Is_Active())
ev_WrongAction.Cancel();
Ev_Wrong_Action();
} | [
"64504737+PoulpePalpitant@users.noreply.github.com"
] | 64504737+PoulpePalpitant@users.noreply.github.com |
067752c52be5e13facb538004522dc2ff22d14a1 | 64178ab5958c36c4582e69b6689359f169dc6f0d | /vscode/wg/sdk/UTwitterIntegrationBase.hpp | 8dfc7393c050f65d064025be9eb18b9cdc179b2a | [] | no_license | c-ber/cber | 47bc1362f180c9e8f0638e40bf716d8ec582e074 | 3cb5c85abd8a6be09e0283d136c87761925072de | refs/heads/master | 2023-06-07T20:07:44.813723 | 2023-02-28T07:43:29 | 2023-02-28T07:43:29 | 40,457,301 | 5 | 5 | null | 2023-05-30T19:14:51 | 2015-08-10T01:37:22 | C++ | UTF-8 | C++ | false | false | 874 | hpp | #pragma once
#include "UPlatformInterfaceBase.hpp"
#ifdef _MSC_VER
#pragma pack(push, 1)
#endif
namespace PUBGSDK {
struct alignas(1) UTwitterIntegrationBase // Size: 0x40
: public UPlatformInterfaceBase // Size: 0x40
{
private:
typedef UTwitterIntegrationBase t_struct;
typedef ExternalPtr<t_struct> t_structHelper;
public:
static ExternalPtr<struct UClass> StaticClass()
{
static ExternalPtr<struct UClass> ptr;
if(!ptr) ptr = UObject::FindClassFast(1182); // id32("Class Engine.TwitterIntegrationBase")
return ptr;
}
};
#ifdef VALIDATE_SDK
namespace Validation{
auto constexpr sizeofUTwitterIntegrationBase = sizeof(UTwitterIntegrationBase); // 64
static_assert(sizeof(UTwitterIntegrationBase) == 0x40, "Size of UTwitterIntegrationBase is not correct.");
}
#endif
}
#ifdef _MSC_VER
#pragma pack(pop)
#endif
| [
"1395329153@qq.com"
] | 1395329153@qq.com |
bcb460490d3e069716a136b0ae6cd8c0dda57e03 | 9755de8a1e3e1075ad298954c8b5e9a3b0d6d139 | /NumericalSineCalculator/sinsolver.h | f5c9e49f12c1cc4d1a0af5dcec08f73ddc0ece80 | [] | no_license | FrozenBurning/Arbitrary-Precision-Sine | 36512fddb090eae119931cc31283ca1e498e23de | de0b5e9405a011b6ad38c5d3de8e443a02b6e709 | refs/heads/master | 2022-04-21T22:10:30.692962 | 2020-03-10T13:18:56 | 2020-03-10T13:18:56 | 223,957,273 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 463 | h | #ifndef SINSOLVER_H
#define SINSOLVER_H
#include <math.h>
#include <iostream>
#define Taylor_Series 0
#define Differential_Equation 1
#define Fourier 2
class SinSolver
{
private:
double _x;
double _h;
int _n;
int _flag;
double taylor_series_method();
double differential_equation_method();
double fourier_method();
public:
SinSolver(double x);
~SinSolver();
double solver_handler(int method);
};
#endif // SINSOLVER_H
| [
"chenzhaoxi0924@126.com"
] | chenzhaoxi0924@126.com |
087d76c6600268123a32e01b1eb3eb7b2fc558e3 | 14248aaedfa5f77c7fc5dd8c3741604fb987de5c | /luogu/P3723.cpp | 007bad902f9b4a45c6eac2ba79468e96ebd7dc50 | [] | no_license | atubo/online-judge | fc51012465a1bd07561b921f5c7d064e336a4cd2 | 8774f6c608bb209a1ebbb721d6bbfdb5c1d1ce9b | refs/heads/master | 2021-11-22T19:48:14.279016 | 2021-08-29T23:16:16 | 2021-08-29T23:16:16 | 13,290,232 | 2 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,486 | cpp | // https://www.luogu.org/problemnew/show/P3723
// [AH2017/HNOI2017]礼物
#include <bits/stdc++.h>
using namespace std;
class Fft {
public:
constexpr const static double PI = 3.14159265359;
static void four1(vector<double> &data, const int isign) {
int nn = data.size() / 2;
int n = nn << 1;
int j = 1;
for (int i = 1; i < n; i+=2) {
if (j > i) {
swap(data[j-1], data[i-1]);
swap(data[j], data[i]);
}
int m = nn;
while (m >= 2 && j > m) {
j -= m;
m >>= 1;
}
j += m;
}
int mmax = 2;
while (n > mmax) {
int istep = mmax << 1;
double theta = isign * (2 * PI / mmax);
double wtemp = sin(0.5 * theta);
double wpr = - 2.0 * wtemp * wtemp;
double wpi = sin(theta);
double wr = 1.0;
double wi = 0.0;
for (int m = 1; m < mmax; m += 2) {
for (int i = m; i <= n; i += istep) {
j = i + mmax;
double tempr = wr * data[j-1] - wi * data[j];
double tempi = wr * data[j] + wi * data[j-1];
data[j-1] = data[i-1] - tempr;
data[j] = data[i] - tempi;
data[i-1] += tempr;
data[i] += tempi;
}
wr = (wtemp=wr)*wpr - wi*wpi + wr;
wi = wi*wpr + wtemp*wpi + wi;
}
mmax = istep;
}
}
static vector<double> innerProduct(const vector<double> &x,
const vector<double> &y) {
const int n = x.size() / 2;
vector<double> ret(2*n);
for (int i = 0; i < n; i++) {
double a = x[2*i], b = x[2*i+1];
double c = y[2*i], d = y[2*i+1];
ret[2*i] = a*c - b*d;
ret[2*i+1] = a*d + b*c;
}
return ret;
}
};
vector<int64_t> rotateProduct(const vector<int>& x, const vector<int> &y) {
const int n = x.size();
int nn = log2(n) + 3;
nn = (1 << nn);
vector<double> a(2*nn), b(2*nn);
for (int i = 0; i < 2*n; i += 2) {
a[i] = x[i/2];
b[i] = b[i+2*n] = y[n-1-i/2];
}
Fft::four1(a, 1);
Fft::four1(b, 1);
vector<double> c = Fft::innerProduct(a, b);
Fft::four1(c, -1);
vector<int64_t> ret(n);
for (int i = 0; i < n; i++) {
ret[i] = c[2*(i+n-1)]/nn + 0.1;
}
return ret;
}
int64_t ans = 1e12;
int N, M;
void solve(int c, const vector<int> &x, vector<int> y) {
int64_t totsq = 0;
for (int i = 0; i < N; i++) {
y[i] += c;
totsq += y[i]*y[i] + x[i]*x[i];
}
vector<int64_t> z = rotateProduct(x, y);
int64_t maxp = *max_element(z.begin(), z.end());
ans = min(ans, totsq - 2*maxp);
}
int main() {
scanf("%d%d", &N, &M);
vector<int> x(N), y(N);
int totx = 0, toty = 0;
for (int i = 0; i < N; i++) {
scanf("%d", &x[i]);
totx += x[i];
}
for (int i = 0; i < N; i++) {
scanf("%d", &y[i]);
toty += y[i];
}
if (totx < toty) {
swap(totx, toty);
swap(x, y);
}
vector<int> cz;
cz.push_back((totx-toty)/N);
if ((totx-toty) % N != 0) {
cz.push_back(cz[0]+1);
}
for (int c: cz) {
solve(c, x, y);
}
printf("%lld\n", ans);
return 0;
}
| [
"err722@yahoo.com"
] | err722@yahoo.com |
73cbcb006857a2a009dfbf88aa39bba7333da63c | 85c5ec5dcb3a78201fab99c61b19763115f33208 | /Codechef/LONGCOOK.cpp | 145ac7e4dfc76c4e1eecc55b1d6a56f492aa947e | [] | no_license | gaurav1620/Competitive-Coding | 3fea83700b5a6d94e4b9b40966222390b92b07de | 9b729b8dcc941cb9187b9bec970b2e56063ca0fc | refs/heads/master | 2023-07-04T06:50:29.584930 | 2021-08-07T15:52:12 | 2021-08-07T15:52:12 | 291,438,389 | 2 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 5,833 | cpp | /*
© GAURAV KHAIRNAR 2019
@ Website : gaurav1620.rf.gd
@ Github : gaurav1620
@ Insta : may_be_gaurav_
@ Gmail : gauravak007@gmail.com
@ CodeForces : gaurav1620
@ CodeChef : gaurav1620
# Dont compare yourself with anyone in this world.If you do so, you are insulting youreself .
*/
#include<bits/stdc++.h>
//Faster loops
#define fo(i,n) for(i = 0;i < n;i++)
#define rfo(i,n) for(i = n-1; n >= 0;i++0)
#define Fo(i,k,n) for(i = k;i < n;i++)
#define oneFo(i,n)for(i = 1;i <=n;i++)
//Renames
#define ll long long
#define pii pair<int,int>
#define vi vector<int>
#define vii vector<vector<int>>
#define pb push_back
//MAX
#define MAXL LONG_MAX
#define MAXI INT_MAX
//MOD
#define mod7 1000000007
#define mod9 1000000009
//Debugging
#define watch(x) cout << (#x) << " is : " << (x) << endl
//Fast functions
template<class T>
inline T fabs(T a){return a>0?a:a*-1;}
using namespace std;
//Functions
void swap(ll &x,ll &y);
bool isPrime(ll n);
ll nCrModp(ll n, ll r, ll p);
ll power(ll x, ll y, ll p);
//Used for modInverse
ll gcdExtended(ll a, ll b, ll *x, ll *y);
//Used for modDivide
ll modInverse(ll b, ll m);
//Use this for modular divisions
ll modDivide(ll a, ll b, ll m);
ll dayofweek(ll d, ll m, ll y)
{
static ll t[] = { 0, 3, 2, 5, 0, 3,
5, 1, 4, 6, 2, 4 };
y -= m < 3;
return ( y + y / 4 - y / 100 +
y / 400 + t[m - 1] + d) % 7;
}
bool isLeapYear(ll y){
if(y%400 == 0)return true;
if(y%100 == 0)return false;
if(y%4 == 0)return true;
return false;
}
ll arr[500];
int main(){
// ios::sync_with_stdio(false);
// cin.tie(NULL);
//▬▬ι═══════>
//Dont forget to use
//map , vector, list
//log ,gcd,lcm
ll t,ii,ans = 0,sum = 0;cin>>t;
//Init arr
arr[0] = 0;
for(ii = 1;ii <= 400;ii++){
ans = 0;
if(isLeapYear(ii)){
if(dayofweek(1,2,ii) == 6){
ans++;
sum++;
}
}else{
if(dayofweek(1,2,ii) == 0 || dayofweek(1,2,ii) == 6){
ans++;
sum++;
}
}
arr[ii] = ans;
}
ll mm = sum;
// fo(ii,61)cout<<arr[ii]<<endl;
while(t--){
ll m1,y1,m2,y2;cin>>m1>>y1>>m2>>y2;
//cout<<getAns(m1,y1,m2,y2)<<endl;
ll x = 0; //28 day febs till now that start with sat or sun
ll y = 0;//29 leap years that start with sun.
if(m1 > 2)y1++;
if(m2 < 2)y2--;
ll i,j,k;
ans = 0;
/*
//556
if(y1%400 != 0){
ans += mm - arr[y1%400];
}
if(y2%400 != 0){
ans += arr[y1%400];
}
ll lft,rgt;
if(y1%400 != 0){
lft = y1/400;
lft++;
lft *= 400;
}else{
lft = y1;
}
if(y2%400 != 0){
rgt = y2/400;
rgt *= 400;
}else{
rgt = y2;
}
ans += ((rgt - lft)/400)*mm;
cout<<ans<<endl;
*/
ll hh = (y1/400 + 1)*400;
ll gg = (y2/400)*400;
for(i = y1;i != hh;i++){
ans+=arr[i%400];
}
for(i = y2;i != gg;i--){
ans+= arr[i%400];
}
ans += ((gg-hh)/400)*mm;
cout<<ans<<endl;
}
//▬▬ι═══════>
return 0;
}
/*
.
M
dM
MMr
4MMML .
MMMMM. xf
. "MMMMM .MM-
Mh.. +MMMMMM .MMMM
.MMM. .MMMMML. MMMMMh
)MMMh. MMMMMM MMMMMMM
3MMMMx. 'MMMMMMf xnMMMMMM"
'*MMMMM MMMMMM. nMMMMMMP"
*MMMMMx "MMMMM\ .MMMMMMM=
*MMMMMh "MMMMM" JMMMMMMP
MMMMMM 3MMMM. dMMMMMM .
MMMMMM "MMMM .MMMMM( .nnMP"
=.. *MMMMx MMM" dMMMM" .nnMMMMM*
"MMn... 'MMMMr 'MM MMM" .nMMMMMMM*"
"4MMMMnn.. *MMM MM MMP" .dMMMMMMM""
^MMMMMMMMx. *ML "M .M* .MMMMMM**"
*PMMMMMMhn. *x > M .MMMM**""
""**MMMMhx/.h/ .=*"
.3P"%....
nP" "*MMnx GaUrAv..
*/
void swap(ll &x,ll &y){
x ^= y;
y ^= x;
x ^= y;
}
bool isPrime(ll n){
if (n <= 1)return false;
for (ll i = 2; i < n; i++)
if (n % i == 0)
return false;
return true;
}
ll nCrModp(ll n, ll r, ll p){
ll C[r+1];
memset(C, 0, sizeof(C));
C[0] = 1;
for (ll i = 1; i <= n; i++){
for (ll j = min(i, r); j > 0; j--)
C[j] = (C[j] + C[j-1])%p;
}
return C[r];
}
ll power(ll x, ll y, ll p){
ll res = 1;
x = x % p;
while (y > 0){
if (y & 1)
res = (res*x) % p;
y = y>>1;
x = (x*x) % p;
}
return res;
}
//Used for modInverse
ll gcdExtended(ll a, ll b, ll *x, ll *y){
if (a == 0){
*x = 0, *y = 1;
return b;
}
ll x1, y1;
ll gcd = gcdExtended(b%a, a, &x1, &y1);
*x = y1 - (b/a) * x1;
*y = x1;
return gcd;
}
//Used for modDivide
ll modInverse(ll b, ll m){
ll x, y;
ll g = gcdExtended(b, m, &x, &y);
if (g != 1)
return -1;
return (x%m + m) % m;
}
//Use this for modular divisions
ll modDivide(ll a, ll b, ll m){
a = a % m;
ll inv = modInverse(b, m);
if (inv == -1)
return -1;
else
return (inv * a) % m;
}
| [
"gauravak007@gmail.com"
] | gauravak007@gmail.com |
a9647063237cbce7ed115ba4924921cf78e2c10a | 38a14aa51557d007d981b2e3a295218796dd6e03 | /Testing/VisuFLTK/otbRenderingImageFilterPhase.cxx | a5c3236e628ef6db4615cf81f53ed81b84d087c4 | [] | no_license | spacefan/Monteverdi | aaa241cc9950ec465bdce4d651cf0038b1300aba | 90edf7b1d5836539d5c723109e9fb53d9458f865 | refs/heads/master | 2021-05-28T21:07:55.319705 | 2015-07-02T10:12:30 | 2015-07-02T10:12:30 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,969 | cxx | /*=========================================================================
Program: ORFEO Toolbox
Language: C++
Date: $Date$
Version: $Revision$
Copyright (c) Centre National d'Etudes Spatiales. All rights reserved.
See OTBCopyright.txt for details.
This software is distributed WITHOUT ANY WARRANTY; without even
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the above copyright notices for more information.
=========================================================================*/
#include "otbRenderingImageFilter.h"
#include "otbVectorImage.h"
#include "otbImage.h"
#include "otbImageFileReader.h"
#include "otbImageFileWriter.h"
#include "itkRGBPixel.h"
#include "otbStandardRenderingFunction.h"
#include "otbPhaseFunctor.h"
int otbRenderingImageFilterPhase(int argc, char * argv[])
{
typedef double PixelType;
typedef otb::VectorImage<PixelType, 2> ImageType;
typedef ImageType::PixelType VectorPixelType;
typedef otb::Image<itk::RGBPixel<unsigned char>, 2> RGBImageType;
typedef otb::RenderingImageFilter<ImageType, RGBImageType> RenderingFilterType;
typedef otb::ImageFileReader<ImageType> ReaderType;
typedef otb::ImageFileWriter<RGBImageType> WriterType;
typedef otb::Function::PhaseFunctor<VectorPixelType> PixelRepresentationFunctionType;
typedef otb::Function::StandardRenderingFunction
<VectorPixelType, itk::RGBPixel<unsigned char>,
PixelRepresentationFunctionType> RenderingFunctionType;
typedef RenderingFilterType::RenderingFunctionType::ParametersType ParametersType;
// Instantiation
ReaderType::Pointer reader = ReaderType::New();
RenderingFilterType::Pointer rendering = RenderingFilterType::New();
WriterType::Pointer writer = WriterType::New();
RenderingFunctionType::Pointer function = RenderingFunctionType::New();
// reading input image
reader->SetFileName(argv[1]);
reader->GenerateOutputInformation();
// min & max
// VectorPixelType min(nbComponents);
// VectorPixelType max(nbComponents);
PixelRepresentationFunctionType::ChannelListType channels;
channels.push_back(atoi(argv[3]));
channels.push_back(atoi(argv[4]));
unsigned int nbComponents = 1; //To be displayed
ParametersType parameters(2 * nbComponents);
for (unsigned int i = 0; i < nbComponents; ++i)
{
parameters[i] = atof(argv[5 + i]);
++i;
parameters[i] = atof(argv[5 + i]);
}
// rendering
rendering->SetInput(reader->GetOutput());
rendering->SetRenderingFunction(function);
function->SetParameters(parameters);
function->GetPixelRepresentationFunction()->SetChannelList(channels);
// writing
writer->SetFileName(argv[2]);
writer->SetInput(rendering->GetOutput());
writer->Update();
return EXIT_SUCCESS;
}
| [
"mickael.savinaud@c-s.fr"
] | mickael.savinaud@c-s.fr |
aa5c733e86894e7a3865af0377f956f75bd6e7e8 | 4449426afd4842c90acfbad9b5ec4d027e2e9a8f | /src/Storage/Record.cc | 84eadc618242caf3779b8c8206051e390441a5af | [] | no_license | yuanhang3260/DBMS | 38a4d005676f56c3bb0a46266bc4d497a3025d93 | c83e4ba75fbe9e1eff177d5474155628dbf2d466 | refs/heads/master | 2020-04-11T23:28:05.734606 | 2017-12-13T07:43:15 | 2017-12-13T07:43:15 | 47,942,052 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 15,962 | cc | #include <climits>
#include <string.h>
#include <iostream>
#include <stdexcept>
#include <algorithm>
#include "Base/Utils.h"
#include "Base/Log.h"
#include "Strings/Split.h"
#include "Strings/Utils.h"
#include "Storage/Record.h"
namespace Storage {
std::string RecordTypeStr(RecordType record_type) {
switch (record_type) {
case INDEX_RECORD:
return "INDEX_RECORD";
case DATA_RECORD:
return "DATA_RECORD";
case TREENODE_RECORD:
return "TREENODE_RECORD";
case UNKNOWN_RECORDTYPE:
return "UNKNOWN_RECORD_TYPE";
}
return "UNKNOWN_RECORDTYPE";
}
// ****************************** RecordID ********************************** //
int RecordID::DumpToMem(byte* buf) const {
if (!buf) {
return -1;
}
memcpy(buf, &page_id_, sizeof(page_id_));
memcpy(buf + sizeof(page_id_), &slot_id_, sizeof(slot_id_));
return sizeof(page_id_) + sizeof(slot_id_);
}
int RecordID::LoadFromMem(const byte* buf) {
if (!buf) {
return -1;
}
memcpy(&page_id_, buf, sizeof(page_id_));
memcpy(&slot_id_, buf + sizeof(page_id_), sizeof(slot_id_));
return sizeof(page_id_) + sizeof(slot_id_);
}
void RecordID::Print() const {
std::cout << "rid = (" << page_id_ << ", " << slot_id_ << ")" << std::endl;
}
// ****************************** RecordBase ******************************** //
uint32 RecordBase::size() const {
uint32 size = 0;
for (const auto& field: fields_) {
size += field->length();
}
return size;
}
void RecordBase::Print() const {
PrintImpl();
std::cout << std::endl;
}
void RecordBase::PrintImpl() const {
std::cout << "Record: | ";
for (auto& field: fields_) {
if (field->type() == Schema::FieldType::STRING ||
field->type() == Schema::FieldType::CHARARRAY) {
std::cout << Schema::FieldTypeStr(field->type()) << ": "
<< "\"" << field->AsString() << "\" | ";
}
else {
std::cout << Schema::FieldTypeStr(field->type()) << ": "
<< field->AsString() << " | ";
}
}
}
void RecordBase::AddField(Schema::Field* new_field) {
fields_.push_back(std::shared_ptr<Schema::Field>(new_field));
}
void RecordBase::AddField(std::shared_ptr<Schema::Field> new_field) {
fields_.push_back(new_field);
}
bool RecordBase::operator<(const RecordBase& other) const {
const auto& other_fields = other.fields();
int len = Utils::Min(fields_.size(), other_fields.size());
for (int i = 0; i < len; i++) {
int re = RecordBase::CompareSchemaFields(
fields_.at(i).get(), other_fields.at(i).get());
if (re < 0) {
return true;
}
else if (re > 0){
return false;
}
}
return fields_.size() < other_fields.size();
}
bool RecordBase::operator>(const RecordBase& other) const {
const auto& other_fields = other.fields();
int len = Utils::Min(fields_.size(), other_fields.size());
for (int i = 0; i < len; i++) {
int re = RecordBase::CompareSchemaFields(
fields_.at(i).get(), other_fields.at(i).get());
if (re > 0) {
return true;
}
else if (re < 0){
return false;
}
}
return fields_.size() > other_fields.size();
}
bool RecordBase::operator<=(const RecordBase& other) const {
return !(*this > other);
}
bool RecordBase::operator>=(const RecordBase& other) const {
return !(*this < other);
}
bool RecordBase::operator==(const RecordBase& other) const {
uint32 len = fields_.size();
if (len != other.fields_.size()) {
return false;
}
const auto& other_fields = other.fields();
for (uint32 i = 0; i < len; i++) {
int re = RecordBase::CompareSchemaFields(
fields_.at(i).get(), other_fields.at(i).get());
if (re != 0) {
return false;
}
}
return true;
}
int RecordBase::CompareRecords(const RecordBase& r1, const RecordBase& r2) {
CHECK(r1.NumFields() == r2.NumFields(),
"records have different number of fields");
for (uint32 i = 0; i < r1.NumFields(); i++) {
CHECK(r1.fields_.at(i)->type() == r2.fields_.at(i)->type(),
"Comparing different types of schema fields!");
int re = RecordBase::CompareSchemaFields(r1.fields_.at(i).get(),
r2.fields_.at(i).get());
if (re < 0) {
return -1;
}
else if (re > 0) {
return 1;
}
}
return 0;
}
int RecordBase::CompareRecordsBasedOnIndex(const RecordBase& r1,
const RecordBase& r2,
const std::vector<uint32>& indexes) {
CHECK(!indexes.empty(), "empty comparing indexes");
for (uint32 i = 0; i < indexes.size(); i++) {
int re = RecordBase::CompareSchemaFields(
r1.fields_.at(indexes[i]).get(),
r2.fields_.at(indexes[i]).get()
);
if (re < 0) {
return -1;
}
else if (re > 0) {
return 1;
}
}
return 0;
}
bool RecordBase::RecordComparator(const RecordBase& r1,
const RecordBase& r2,
const std::vector<uint32>& indexes) {
return CompareRecordsBasedOnIndex(r1, r2, indexes) < 0;
}
bool RecordBase::RecordComparatorGt(const RecordBase& r1,
const RecordBase& r2,
const std::vector<uint32>& indexes) {
return CompareRecordsBasedOnIndex(r1, r2, indexes) > 0;
}
int RecordBase::CompareRecordWithKey(const RecordBase& record,
const RecordBase& key,
const std::vector<uint32>& indexes) {
CHECK(!indexes.empty(), "empty comparing indexes");
CHECK(key.NumFields() == indexes.size(),
"Number of key fields mismatch with indexes to compare");
for (uint i = 0; i < indexes.size(); i++) {
int re = RecordBase::CompareSchemaFields(
record.fields_.at(indexes[i]).get(),
key.fields_.at(i).get()
);
if (re < 0) {
return -1;
}
else if (re > 0) {
return 1;
}
}
return 0;
}
bool RecordBase::operator!=(const RecordBase& other) const {
return !(*this == other);
}
#define COMPARE_FIELDS_WITH_TYPE(TYPE, FIELD1, FIELD2) \
const TYPE& f1 = *dynamic_cast<const TYPE*>(FIELD1); \
const TYPE& f2 = *dynamic_cast<const TYPE*>(FIELD2); \
if (f1 < f2) { \
return -1; \
} \
if (f1 > f2) { \
return 1; \
} \
return 0; \
int RecordBase::CompareSchemaFields(const Schema::Field* field1,
const Schema::Field* field2) {
if (!field1 && !field2) {
return 0;
}
if (!field1) {
return -1;
}
if (!field2) {
return 1;
}
auto type = field1->type();
CHECK(type == field2->type(), "Comparing different types of schema fields!");
if (type == Schema::FieldType::INT) {
COMPARE_FIELDS_WITH_TYPE(Schema::IntField, field1, field2);
}
if (type == Schema::FieldType::LONGINT) {
COMPARE_FIELDS_WITH_TYPE(Schema::LongIntField, field1, field2);
}
if (type == Schema::FieldType::DOUBLE) {
COMPARE_FIELDS_WITH_TYPE(Schema::DoubleField, field1, field2);
}
if (type == Schema::FieldType::BOOL) {
COMPARE_FIELDS_WITH_TYPE(Schema::BoolField, field1, field2);
}
if (type == Schema::FieldType::CHAR) {
COMPARE_FIELDS_WITH_TYPE(Schema::CharField, field1, field2);
}
if (type == Schema::FieldType::STRING) {
COMPARE_FIELDS_WITH_TYPE(Schema::StringField, field1, field2);
}
if (type == Schema::FieldType::CHARARRAY) {
COMPARE_FIELDS_WITH_TYPE(Schema::CharArrayField, field1, field2);
}
throw std::runtime_error("Compare Schema Fields - Should NOT Reach Here.");
return 0;
}
int RecordBase::DumpToMem(byte* buf) const {
if (!buf) {
return -1;
}
uint32 offset = 0;
for (const auto& field: fields_) {
offset += field->DumpToMem(buf + offset);
}
if (offset != RecordBase::size()) {
LogFATAL("Record dump %d byte, record.size() = %d", offset, size());
}
return offset;
}
int RecordBase::LoadFromMem(const byte* buf) {
if (!buf) {
return -1;
}
uint32 offset = 0;
for (const auto& field: fields_) {
offset += field->LoadFromMem(buf + offset);
}
if (offset != RecordBase::size()) {
LogFATAL("Record load %d byte, record.size() = %d", offset, size());
}
return offset;
}
int RecordBase::InsertToRecordPage(RecordPage* page) const {
int slot_id = page->InsertRecord(size());
if (slot_id >= 0) {
// Write the record content to page.
DumpToMem(page->Record(slot_id));
return slot_id;
}
return -1;
}
RecordBase* RecordBase::Duplicate() const {
RecordBase* new_record = new RecordBase();
new_record->fields_ = fields_;
return new_record;
}
bool RecordBase::CopyFieldsFrom(const RecordBase& source) {
fields_ = source.fields_;
return true;
}
void RecordBase::reset() {
for (auto& field: fields_) {
field->reset();
}
}
void RecordBase::clear() {
fields_.clear();
}
void RecordBase::AddField(const DB::TableField& field_info) {
auto field_type = field_info.type();
if (field_type == Schema::FieldType::INT) {
AddField(new Schema::IntField());
}
if (field_type == Schema::FieldType::LONGINT) {
AddField(new Schema::LongIntField());
}
if (field_type == Schema::FieldType::DOUBLE) {
AddField(new Schema::DoubleField());
}
if (field_type == Schema::FieldType::BOOL) {
AddField(new Schema::BoolField());
}
if (field_type == Schema::FieldType::CHAR) {
AddField(new Schema::CharField());
}
if (field_type == Schema::FieldType::STRING) {
AddField(new Schema::StringField());
}
if (field_type == Schema::FieldType::CHARARRAY) {
AddField(new Schema::CharArrayField(field_info.size()));
}
}
bool RecordBase::InitRecordFields(const DB::TableInfo& schema,
const std::vector<uint32>& indexes) {
clear();
for (int index: indexes) {
AddField(schema.fields(index));
}
return true;
}
// Check fields type match a schema.
bool RecordBase::CheckFieldsType(const DB::TableInfo& schema,
std::vector<uint32> key_indexes) const {
if (fields_.size() != key_indexes.size()) {
LogERROR("Index/TreeNode record has mismatchig number of fields - "
"key has %d fields, record has %d fields",
key_indexes.size(), fields_.size());
return false;
}
for (int i = 0; i < (int)key_indexes.size(); i++) {
if (!fields_[i] || !fields_[i]->MatchesSchemaType(
schema.fields(key_indexes[i]).type())) {
LogERROR("Index/TreeNode record has mismatchig field type with schema "
"field %d", key_indexes[i]);
return false;
}
}
return true;
}
bool RecordBase::CheckFieldsType(const DB::TableInfo& schema) const {
if ((int)fields_.size() != schema.fields_size()) {
LogERROR("Data record has mismatchig number of fields with schema - "
"schema has %d indexes, record has %d",
schema.fields_size(), fields_.size());
return false;
}
for (int i = 0; i < (int)schema.fields_size(); i++) {
if (!fields_[i] || !fields_[i]->MatchesSchemaType(
schema.fields(i).type())) {
LogERROR("Data record has mismatchig field type with schema field %d", i);
return false;
}
}
return true;
}
bool RecordBase::ParseFromText(std::string str, int chararray_len_limit) {
auto tokens = Strings::Split(str, '|');
for (auto& block: tokens) {
block = Strings::Strip(block);
if (block.length() == 0) {
continue;
}
auto pieces = Strings::Split(block, ':');
if ((int)pieces.size() != 2) {
continue;
}
for (int i = 0; i < (int)pieces.size(); i++) {
pieces[i] = Strings::Strip(pieces[i]);
pieces[i] = Strings::Strip(pieces[i], "\"\"");
}
if (pieces[0] == "Int") {
AddField(new Schema::IntField(std::stoi(pieces[1])));
}
else if (pieces[0] == "LongInt") {
AddField(new Schema::LongIntField(std::stol(pieces[1])));
}
else if (pieces[0] == "Double") {
AddField(new Schema::DoubleField(std::stod(pieces[1])));
}
else if (pieces[0] == "Bool") {
AddField(new Schema::BoolField(std::stoi(pieces[1])));
}
else if (pieces[0] == "String") {
AddField(new Schema::StringField(pieces[1]));
}
else if (pieces[0] == "CharArray") {
AddField(new Schema::CharArrayField(pieces[1], chararray_len_limit));
}
}
return (int)fields_.size() > 0;
}
// ****************************** DataRecord ******************************** //
bool DataRecord::ExtractKey(
RecordBase* key, const std::vector<uint32>& key_indexes) const {
if (!key) {
return false;
}
key->fields().clear();
for (uint32 index: key_indexes) {
if (index > fields_.size()) {
LogERROR("key_index %d > number of fields, won't fetch");
continue;
}
key->fields().push_back(fields_.at(index));
}
return true;
}
RecordBase* DataRecord::Duplicate() const {
DataRecord* new_record = new DataRecord();
new_record->fields_ = fields_;
return new_record;
}
// ***************************** IndexRecord ******************************** //
int IndexRecord::DumpToMem(byte* buf) const {
if (!buf) {
return -1;
}
uint32 offset = RecordBase::DumpToMem(buf);
offset += rid_.DumpToMem(buf + offset);
if (offset != size()) {
LogFATAL("IndexRecord DumpToMem error - expect %d bytes, actual %d",
size(), offset);
}
return offset;
}
int IndexRecord::LoadFromMem(const byte* buf) {
if (!buf) {
return -1;
}
uint32 offset = RecordBase::LoadFromMem(buf);
offset += rid_.LoadFromMem(buf + offset);
if (offset != size()) {
LogFATAL("IndexRecord LoadFromMem error - expect %d bytes, actual %d",
size(), offset);
}
return offset;
}
void IndexRecord::Print() const {
RecordBase::PrintImpl();
rid_.Print();
}
uint32 IndexRecord::size() const {
return RecordBase::size() + rid_.size();
}
RecordBase* IndexRecord::Duplicate() const {
IndexRecord* new_record = new IndexRecord();
new_record->fields_ = fields_;
new_record->rid_ = rid_;
return new_record;
}
void IndexRecord::reset() {
RecordBase::reset();
rid_.set_page_id(-1);
rid_.set_slot_id(-1);
}
// **************************** TreeNodeRecord ****************************** //
int TreeNodeRecord::DumpToMem(byte* buf) const {
if (!buf) {
return -1;
}
uint32 offset = RecordBase::DumpToMem(buf);
memcpy(buf + offset, &page_id_, sizeof(page_id_));
offset += sizeof(page_id_);
if (offset != size()) {
LogFATAL("TreeNodeRecord DumpToMem error - expect %d bytes, actual %d",
size(), offset);
}
return offset;
}
int TreeNodeRecord::LoadFromMem(const byte* buf) {
if (!buf) {
return -1;
}
uint32 offset = RecordBase::LoadFromMem(buf);
memcpy(&page_id_, buf + offset, sizeof(page_id_));
offset += sizeof(page_id_);
if (offset != size()) {
LogFATAL("TreeNodeRecord LoadFromMem error - expect %d bytes, actual %d",
size(), offset);
}
return offset;
}
void TreeNodeRecord::Print() const {
RecordBase::PrintImpl();
std::cout << "page_id = " << page_id_ << std::endl;
}
uint32 TreeNodeRecord::size() const {
return RecordBase::size() + sizeof(page_id_);
}
RecordBase* TreeNodeRecord::Duplicate() const {
TreeNodeRecord* new_record = new TreeNodeRecord();
new_record->fields_ = fields_;
new_record->page_id_ = page_id_;
return new_record;
}
void TreeNodeRecord::reset() {
RecordBase::reset();
page_id_ = -1;
}
} // namespace Storage
| [
"yuanhang3260@gmail.com"
] | yuanhang3260@gmail.com |
f55cd64dd7c21383759ccdac0d51df3dfe2bb9f2 | a380c203330d133ec92fa555b9d0611c85fdaff6 | /Arduino/Capteurs/Particules/PPD42NS/particules/particules.ino | 6eba926e6cc7ab56e473f4b870b58fe3986c7fae | [] | no_license | Snoz58/smrtcty | 172fe11f0e71e43a63f8d7932be8ad65ceab4e01 | 9130976f66407aa6729ae79aee286291b5a111a5 | refs/heads/master | 2021-06-19T15:48:30.255961 | 2019-08-27T13:18:15 | 2019-08-27T13:18:15 | 114,651,883 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,034 | ino | #include "math.h"
int pin = 6;
unsigned long duration;
unsigned long starttime;
unsigned long sampletime_ms = 30000;//sampe 30s ;
unsigned long lowpulseoccupancy = 0;
float ratio = 0;
float concentration = 0;
float concentrationm3 = 0;
float pm25 = 0;
float pm10 = 0;
void setup() {
Serial.begin(9600);
pinMode(8,INPUT);
starttime = millis();//get the current time;
}
void loop() {
duration = pulseIn(pin, LOW);
lowpulseoccupancy = lowpulseoccupancy+duration;
if ((millis()-starttime) > sampletime_ms)//if the sampel time == 30s
{
ratio = lowpulseoccupancy/(sampletime_ms*10.0); // Integer percentage 0=>100
concentration = 1.1*pow(ratio,3)-3.8*pow(ratio,2)+520*ratio+0.62; // using spec sheet curve
concentrationm3 = (1.1*pow(ratio,3)-3.8*pow(ratio,2)+520*ratio+0.62)/0.000283168;
pm10 = concentrationm3 * 0.00014356324;
double r10 = 2.6 * pow(10, -6);
double pi = 3.14159;
double vol10 = (4 / 3) * pi * pow(r10, 3);
double density = 1.65 * pow(10, 12);
double mass10 = density * vol10;
double K = 3531.5;
float PM10conc = (pm10) * K * mass10;
double DensityParticle = 1.65*pow(10,12); // Densité moyenne d'une particule en microgramme par mètre cube
double Conversion = 3531.5; // Conversion 0.001 cu ft (comptage du nb de particules par 0.001 cu ft) en m3
double RayonPM10 = 2.6*pow(10,-6); // Rayon particules PM10 en m
double VolumePM10 = (4/3) * PI * pow(RayonPM10,3); // Volume d'une particule PM10 en m3
double MassePM10 = DensityParticle * VolumePM10; // Masse d'une particule PM10 en microgramme
double ConcentrationPM10 = concentration*Conversion*MassePM10; // Concentration de particules PM10 en microgramme par mètre cube
Serial.print("concentration = ");
Serial.print(concentration);
Serial.print(" pcs/0.01cf - ");
Serial.print(PM10conc);
Serial.print(" pcs/m3 - ");
Serial.print(pm10);
Serial.print(" ug/m3");
Serial.print(ConcentrationPM10);
Serial.println(" ug/m3");
Serial.println("\n");
lowpulseoccupancy = 0;
starttime = millis();
}
}
| [
"corentin.metenier@gmail.com"
] | corentin.metenier@gmail.com |
e9fb38d1cfb9cfe97c6a8ee0be5ddfe83852411e | e741bdbd046f87157142908ee5e261a1beda16aa | /rec/rpc/Server.cpp | b35e16be6c625d173e4af8ff651f2701ed21ba85 | [] | no_license | yangfuyuan/rec_rpc-1.0.0 | a52a4e6c97a8acad863f19c19ceb7333f7959967 | 9ae79a784d8ad9c0d784cc8213900f77c0ea1f72 | refs/heads/master | 2020-07-31T08:34:06.080252 | 2016-11-13T07:35:44 | 2016-11-13T07:35:44 | 73,602,528 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,477 | cpp | /*
Copyright (c) 2011, REC Robotics Equipment Corporation GmbH, Planegg, Germany
All rights reserved.
Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:
- Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
- 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.
- Neither the name of the REC Robotics Equipment Corporation GmbH 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.
*/
#include "rec/rpc/Server.h"
#include "rec/rpc/server/Server.hpp"
#include <cassert>
using namespace rec::rpc;
Server::Server()
: _server( 0 )
{
_server = new server::Server;
//bool ok = true;
connect( _server, SIGNAL( listening() ), SIGNAL( listening() ), Qt::QueuedConnection );
connect( _server, SIGNAL( closed() ), SIGNAL( closed() ), Qt::QueuedConnection );
connect( _server
, SIGNAL( clientConnected( const QHostAddress&, unsigned short ) )
, SIGNAL( clientConnected( const QHostAddress&, unsigned short ) )
, Qt::QueuedConnection );
connect( _server
, SIGNAL( clientDisconnected( const QHostAddress&, unsigned short ) )
, SIGNAL( clientDisconnected( const QHostAddress&, unsigned short ) )
, Qt::QueuedConnection );
connect( _server
, SIGNAL( serverError( QAbstractSocket::SocketError, const QString& ) )
, SIGNAL( serverError( QAbstractSocket::SocketError, const QString& ) )
, Qt::QueuedConnection );
connect( _server
, SIGNAL( clientError( QAbstractSocket::SocketError, const QString& ) )
, SIGNAL( clientError( QAbstractSocket::SocketError, const QString& ) )
, Qt::QueuedConnection );
connect( _server
, SIGNAL( registeredTopicListener( const QString&, const QHostAddress&, unsigned short ) )
, SIGNAL( registeredTopicListener( const QString&, const QHostAddress&, unsigned short ) )
, Qt::QueuedConnection );
connect( _server
, SIGNAL( unregisteredTopicListener( const QString&, const QHostAddress&, unsigned short ) )
, SIGNAL( unregisteredTopicListener( const QString&, const QHostAddress&, unsigned short ) )
, Qt::QueuedConnection );
connect( qApp, SIGNAL( aboutToQuit() ), SLOT( close() ) );
//assert( ok );
}
Server::~Server()
{
delete _server;
}
void Server::listen( int port )
{
_server->listen( port );
}
void Server::close()
{
_server->close();
}
bool Server::isListening() const
{
return _server->isListening();
}
unsigned short Server::serverPort() const
{
return _server->serverPort();
}
QString Server::greeting() const
{
return _server->greeting();
}
void Server::setGreeting( const QString& greeting )
{
_server->setGreeting( greeting );
}
void Server::publishTopic( const QString& name, serialization::SerializablePtrConst data )
{
_server->publishTopic( name, data );
}
void Server::addTopic( const QString& name, int sharedMemorySize )
{
_server->addTopic( name, sharedMemorySize );
}
void Server::registerTopicListener( const QString& name, TopicListenerBase* listener )
{
_server->registerTopicListener( name, listener );
}
void Server::unregisterTopicListener( const QString& name )
{
_server->unregisterTopicListener( name );
}
void Server::registerFunction( const QString& name, RPCFunctionBase* function )
{
_server->registerFunction( name, function );
}
void Server::unregisterFunction( const QString& name )
{
_server->unregisterFunction( name );
}
| [
"chushuifurong618@126.com"
] | chushuifurong618@126.com |
80c61d379df04817cf832ad58c9d81de7041c54a | 5e8d200078e64b97e3bbd1e61f83cb5bae99ab6e | /main/source/src/core/chemical/automorphism.hh | cd466f64ca4700d3f196fa19fb5f11ab55d08828 | [] | no_license | MedicaicloudLink/Rosetta | 3ee2d79d48b31bd8ca898036ad32fe910c9a7a28 | 01affdf77abb773ed375b83cdbbf58439edd8719 | refs/heads/master | 2020-12-07T17:52:01.350906 | 2020-01-10T08:24:09 | 2020-01-10T08:24:09 | 232,757,729 | 2 | 6 | null | null | null | null | UTF-8 | C++ | false | false | 5,288 | hh | // -*- mode:c++;tab-width:2;indent-tabs-mode:t;show-trailing-whitespace:t;rm-trailing-spaces:t -*-
// vi: set ts=2 noet:
//
// (c) Copyright Rosetta Commons Member Institutions.
// (c) This file is part of the Rosetta software suite and is made available under license.
// (c) The Rosetta software is developed by the contributing members of the Rosetta Commons.
// (c) For more information, see http://www.rosettacommons.org. Questions about this can be
// (c) addressed to University of Washington CoMotion, email: license@uw.edu.
/// @file core/chemical/automorphism.hh
///
/// @brief
/// @author Ian W. Davis
#ifndef INCLUDED_core_chemical_automorphism_hh
#define INCLUDED_core_chemical_automorphism_hh
#include <core/chemical/ResidueType.hh>
#include <utility/vector1.hh>
namespace core {
namespace chemical {
class AutomorphismIterator; // fwd declaration
typedef utility::pointer::shared_ptr< AutomorphismIterator > AutomorphismIteratorOP;
typedef utility::pointer::shared_ptr< AutomorphismIterator const > AutomorphismIteratorCOP;
/// @brief Enumerates the automorphisms of a residue, which are basically
/// chemical symmetries that affect RMSD calculations.
///
/// @details Common automorphisms include flipping a phenyl ring (think Phe chi2)
/// or rotating a methyl group (or CF3, if you don't care about H).
/// However, they can be much more complicated than that,
/// and some cannot be imitated by rotation about a bond.
/// Examples include labeling a -CF3 clockwise vs. counterclockwise,
/// or swapping the -CF3 branches of -C(CF3)2R.
/// See the ligand of PDB 1PQC for a reasonably complex example.
///
/// Formally, a graph automorphism is an isomorphism of that graph with itself:
/// given a graph G(V,E) and a mapping M that relabels the vertices
/// according to M(v) -> v', then M is an automorphism iff
/// (M(u),M(v)) is an edge if and only if (u,v) is an edge.
/// If the vertices are "colored" (in our case, have atom types), it must also
/// be true that M(v) and v have the same color, for all v in V.
///
/// Thus you can re-label a phenyl ring
///
/// 2 3 6 5 6 3
/// 1 4 or 1 4 but not 1 4
/// 6 5 2 3 2 5
///
/// because in the last case, there are new bonds 6-3 and 2-5,
/// and missing bonds 6-5 and 2-3.
///
/// See also: OpenEye's OEChem library and its OERMSD() function.
///
class AutomorphismIterator : public utility::pointer::ReferenceCount
{
public:
/// @brief Including H will lead to many, many more automorphisms!
AutomorphismIterator(ResidueType const & restype, bool includeH = false):
restype_(restype),
restype2_(restype),
empty_list_()
{
natoms_ = (includeH ? restype_.natoms() : restype_.nheavyatoms());
curr_.assign(natoms_, 1); // = [1, 1, 1, ..., 1]
}
/// @brief The mapping returned will be from restype to restype2
/// Including H will lead to many, many more automorphisms!
AutomorphismIterator(ResidueType const & restype, ResidueType const & restype2, bool includeH = false):
restype_(restype),
restype2_(restype2),
empty_list_()
{
natoms_ = (includeH ? restype_.natoms() : restype_.nheavyatoms());
core::Size natoms2 = (includeH ? restype2_.natoms() : restype2_.nheavyatoms());
runtime_assert( natoms_ == natoms2 );
curr_.assign(natoms_, 1); // = [1, 1, 1, ..., 1]
}
~AutomorphismIterator() override = default;
/// @brief Returns the next automorphism for this residue type
/// as a vector that maps "old" atom indices to "new" atom indices.
/// Returns an empty vector when no more automorphisms remain.
utility::vector1<Size>
next();
private:
/// @brief Are atoms i and j potentially interchangeable?
/// @details We want this check to be fast but also to eliminate
/// as many potential pairings as possible.
/// We currently check (1) atom types and (2) number of neighbors.
/// We could potentially also check atom types of neighbors,
/// but that costs a set comparison or two array sorts, so we don't right now.
inline
bool
can_pair(Size i, Size j);
/// @brief Does the current mapping preserve all edges?
/// @details That is, if (i,j) is an edge, is (curr_[i],curr_[j]) also an edge?
/// Checks all edges (i,j) where j < i, for the supplied i.
/// (Edges with j > i can't be checked becaues curr_[j] isn't valid yet.)
inline
bool
edges_match(Size i) {
AtomIndices const & nbrs = restype_.nbrs(i);
for ( Size idx = 1, end = nbrs.size(); idx <= end; ++idx ) {
Size const j = nbrs[idx];
if ( j > i ) continue;
if ( !bonded2( curr_[i], curr_[j] ) ) return false;
}
return true;
}
/* // Commented out for cppcheck
/// @brief Are atoms i and j bonded to each other on Restype1?
inline
bool
bonded(Size i, Size j) {
return restype_.path_distance(i,j) == 1;
}
*/
/// @brief Are atoms i and j bonded to each other on Restype2?
inline
bool
bonded2(Size i, Size j) {
return restype2_.path_distance(i,j) == 1;
}
private:
ResidueType const & restype_;
ResidueType const & restype2_;
Size natoms_;
/// curr_[i] = current partner for atom i
utility::vector1<Size> curr_;
utility::vector1<Size> const empty_list_;
}; // AutomorphismIterator
} // namespace chemical
} // namespace core
#endif // INCLUDED_core_chemical_automorphism_HH
| [
"36790013+MedicaicloudLink@users.noreply.github.com"
] | 36790013+MedicaicloudLink@users.noreply.github.com |
2e4600e07b9c6113c413443f3d13a8f5af973543 | fb2e13219f4ca0ea51ce4baa7abf12b229246abc | /leetcode/SymmetricTree/rec.cc | 62ea46bce0ce81a8e4d4308224c517a79e39276f | [] | no_license | lewischeng-ms/online-judge | 7ca1e91ff81e8713c85cbec0aa0509a929854af9 | b09d985cfc1026ad2258c2507d7022d7774b01ef | refs/heads/master | 2021-01-22T01:28:19.095275 | 2015-07-10T13:21:57 | 2015-07-10T13:21:57 | 15,488,315 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 806 | cc | /**
* Definition for binary tree
* struct TreeNode {
* int val;
* TreeNode *left;
* TreeNode *right;
* TreeNode(int x) : val(x), left(NULL), right(NULL) {}
* };
*/
class Solution {
public:
bool helper(TreeNode *p, TreeNode *q) {
// Start typing your C/C++ solution below
// DO NOT write int main() function
if (!p && !q)
return true;
else if (!p && q)
return false;
else if (p && !q)
return false;
if (p->val != q->val)
return false;
return helper(p->left, q->right) && helper(p->right, q->left);
}
bool isSymmetric(TreeNode *root) {
// Start typing your C/C++ solution below
// DO NOT write int main() function
if (!root) return true;
return helper(root->left, root->right);
}
}; | [
"lewischeng@Lewis-Chengs-MacBook-Air.local"
] | lewischeng@Lewis-Chengs-MacBook-Air.local |
3e4f977bae1a4f7e3deb80772c6fcec7a9216d95 | 167d57480690ab763ee6e31b6cc6b3a5028d2587 | /check.cpp | 11cbc75d991e8699dcdc5f705827e999c298c5c4 | [] | no_license | shagunsodhani/assembler | 8b35672e09a19d38799af9b8767f0383ce887c57 | b87b9d26e476af2ab3379bd202d97a2b6f814186 | refs/heads/master | 2016-09-05T22:56:57.296034 | 2012-11-28T14:02:05 | 2012-11-28T14:02:05 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,074 | cpp | /* This file contains the code to check which string is larger
* */
#include <iostream>
#include <string>
using namespace std;
bool chk(string a,string b)
{
int p,q,diff,d;
p = a.length();
q = b.length();
if(p>q)
diff = p-q;
else
diff = q-p;
if((a[0]!='0')&&(p>q))
return 1;
else if ((a[0]=='0')&&(p>q))
{
for(int i=0;i<q;i++)
{
if(a[diff+i]>b[i])
return 1;
else if (a[diff+i]<b[i])
return 0;
}
}
else if(p==q)
{
for(int i=0;i<q;i++)
{
if(a[i]>b[i])
return 1;
else if (a[i]<b[i])
return 0;
}
}
else if(p<q)
{
for(int i = 0;i<diff;i++)
{
if(b[i]=='0')
d = 1;
else
d = 0;break;
}
if(d==0)
return 0;
else
{
for(int i =0;i<p;i++)
{
if(a[i]>b[diff+i])
return 1;
else if (a[i]<b[diff+i])
return 0;
}
}
}
}
| [
"sshagun.sodhani@gmail.com"
] | sshagun.sodhani@gmail.com |
a8c1009fcc0c85317c25feab2b93b1aeadc1eeae | f8e09dcd697b8d5576c69c76aeff399dae6c06bd | /src/MetaJoint.cpp | 49cd9cf2dc92b820e5c4534f04c99f1daec319ae | [] | no_license | RyanYoung25/maestor | 5baef1b79e616cb63650873c0e19047c798d59f3 | 0ddff92a6088bc571f900b4d59c63abe21acd968 | refs/heads/master | 2021-01-25T07:40:16.742070 | 2015-07-09T13:24:52 | 2015-07-09T13:24:52 | 17,982,335 | 4 | 3 | null | null | null | null | UTF-8 | C++ | false | false | 4,977 | cpp | /*
Copyright (c) 2013, Drexel University, iSchool, Applied Informatics Group
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* 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.
* Neither the name of the <organization> 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 AUTHORS 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.
*/
/**
* A metajoint object. This is extended by ArmMetaJoint but for all
* the other metajoints in MAESTOR they are objects of this class
*/
#include "MetaJoint.h"
/**
* Create a metajoint and tell it it's controller
*/
MetaJoint::MetaJoint(MetaJointController* controller){
this->controller = controller;
this->position = 0;
this->ready = false;
}
/**
* Destructor
*/
MetaJoint::~MetaJoint() {}
/**
* Get the property of this metajoint. Store it in the pointer that is passed in.
*
* @param property The property that you want to ask about
* @param value A pointer to store the result in
* @return True on success
*/
bool MetaJoint::get(PROPERTY property, double &value){
switch (property){
case ENABLED:
value = true;
break;
case GOAL:
value = this->currGoal;
break;
case INTERPOLATION_STEP:
if (!ready){
ready = true;
controller->setInverse();
} else{
value = interpolate();
}
break;
case POSITION:
controller->getForward();
value = position;
break;
case READY:
value = ready;
break;
case VELOCITY:
value = interVel;
break;
default:
return false;
}
return true;
}
/**
* Set the property of this metajoint to the value passed in
*
* @param property The property to set
* @param value The value to set it to
* @return True on success
*/
bool MetaJoint::set(PROPERTY property, double value){
double currVel;
double newVia;
switch (property){
case META_VALUE:
position = value;
break;
case POSITION:
case GOAL:
controller->update();
if (value == interStep){
break;
}
currVel = (currStepCount != 0 && currParams.valid) ?
(interpolateFourthOrder(currParams, currStepCount) - interpolateFourthOrder(currParams, currStepCount - 1)) : 0;
if (!startParams.valid){
currStepCount = 0;
totalStepCount = totalTime(interStep, value, currVel, interVel) * frequency;
if (totalStepCount > 0) {
startParams = initFourthOrder(interStep, currVel, (value + interStep)/2, (double)totalStepCount / 2, value, totalStepCount);
currParams = startParams;
}
lastGoal = interStep;
} else if (currStepCount != currParams.tv) {
newVia = (startParams.ths + interpolateFourthOrder(currParams, currStepCount));
totalStepCount = currStepCount + (totalTime(newVia, value, currVel, interVel) * frequency);
currParams = initFourthOrder( startParams.ths, currVel, newVia, currStepCount, value, totalStepCount );
}
currGoal = value;
break;
case SPEED:
case VELOCITY:
if (value > 0)
interVel = value;
break;
case READY:
ready = (bool)value;
break;
case INTERPOLATION_STEP:
currParams.valid = false;
startParams.valid = false;
totalStepCount = 0;
currStepCount = 0;
break;
default:
return false;
}
return true;
}
/**
* Set the goal and everything to that position
* @param pos The position to set it all to
*/
void MetaJoint::setGoal(double pos){
currGoal = pos;
interStep = pos;
lastGoal = pos;
}
| [
"Ryan@rdyoung.us"
] | Ryan@rdyoung.us |
63c9990ecf2b53d2251690027c0dd934039f51d0 | c6da2e91c81b08f270bfc956f1258bc0ac19bdfc | /include/socket_t/proto_socket.h | 7f988101f91d13ca605f5c9b4b9d2b3f9886c390 | [
"MIT"
] | permissive | ognian-/socket_t | ef9b750e60f99bff77d2da531e0a397a625c7e89 | 75d2fec8be215341b6970839f00042dc979c0ffa | refs/heads/master | 2021-09-21T01:03:50.081364 | 2018-08-17T12:31:29 | 2018-08-17T12:31:29 | 112,351,231 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,928 | h | #ifndef SOCKET_T_PROTO_SOCKET_H
#define SOCKET_T_PROTO_SOCKET_H
#include <chrono>
#include <sys/socket.h>
#include <sys/time.h>
#include "socket_t/sockopt.h"
SOCKT_NAMESPACE_BEGIN
class timeout_t {
public:
template<typename Rep, typename Period>
constexpr timeout_t(const std::chrono::duration<Rep, Period>& time);
constexpr timeout_t(const ::timeval& time);
constexpr operator ::timeval() const;
constexpr operator const std::chrono::microseconds&() const;
constexpr bool operator==(const timeout_t& other) const;
constexpr bool operator!=(const timeout_t& other) const;
private:
const std::chrono::microseconds m_time;
};
class linger_t {
public:
constexpr linger_t(int seconds);
constexpr linger_t(const ::linger& in);
constexpr operator ::linger() const;
constexpr bool get_enabled() const;
constexpr int get_seconds() const;
private:
const bool m_enabled;
const int m_seconds;
};
class proto_socket {
~proto_socket() = delete;
public:
using acceptconn = sockopt<SOL_SOCKET, SO_ACCEPTCONN, int, true, false, bool>;
using reuseaddr = sockopt<SOL_SOCKET, SO_REUSEADDR, int, false, true, bool>;
using rcvbuf = sockopt<SOL_SOCKET, SO_RCVBUF, int, true, true>;
using sndbuf = sockopt<SOL_SOCKET, SO_SNDBUF, int, true, true>;
using rcvtimeo = sockopt<SOL_SOCKET, SO_RCVTIMEO, ::timeval, true, true, timeout_t>;
using sndtimeo = sockopt<SOL_SOCKET, SO_SNDTIMEO, ::timeval, true, true, timeout_t>;
using linger = sockopt<SOL_SOCKET, SO_LINGER, ::linger, true, true, linger_t>;
};
template<typename Rep, typename Period>
constexpr timeout_t::timeout_t(const std::chrono::duration<Rep, Period>& time) :
m_time{time} {}
constexpr timeout_t::timeout_t(const ::timeval& time) :
timeout_t{std::chrono::seconds(time.tv_sec) + std::chrono::microseconds(time.tv_usec)} {}
constexpr timeout_t::operator ::timeval() const {
::timeval out{};
auto sec = std::chrono::duration_cast<std::chrono::seconds>(m_time);
out.tv_sec = sec.count();
out.tv_usec = std::chrono::duration_cast<std::chrono::microseconds>(m_time - sec).count();
return out;
}
constexpr timeout_t::operator const std::chrono::microseconds&() const {
return m_time;
}
constexpr bool timeout_t::operator==(const timeout_t& other) const {
return m_time == other.m_time;
}
constexpr bool timeout_t::operator!=(const timeout_t& other) const {
return m_time != other.m_time;
}
constexpr linger_t::linger_t(int seconds) : m_enabled{seconds >= 0}, m_seconds{seconds >= 0 ? seconds : 0} {}
constexpr linger_t::linger_t(const ::linger& in) : m_enabled{in.l_linger != 0}, m_seconds{in.l_linger} {}
constexpr linger_t::operator ::linger() const {
::linger out{};
out.l_onoff = m_enabled ? 1 : 0;
out.l_linger = m_seconds;
return out;
}
constexpr bool linger_t::get_enabled() const {
return m_enabled;
}
constexpr int linger_t::get_seconds() const {
return m_seconds;
}
SOCKT_NAMESPACE_END
#endif // SOCKET_T_PROTO_SOCKET_H
| [
"ognian@mokriya.com"
] | ognian@mokriya.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.