This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Queue implementation -*- C++ -*- | |
| // Copyright (C) 2001-2014 Free Software Foundation, Inc. | |
| // | |
| // This file is part of the GNU ISO C++ Library. This library 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, or (at your option) | |
| // any later version. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include <vector> | |
| #include <memory> | |
| int main() | |
| { | |
| //! (*v).push_back(),这样对vector似乎并不适用。 | |
| //! | |
| //! -- check the code blew | |
| auto p = std::make_shared<std::vector<int>>(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include <fstream> | |
| #include <locale> | |
| #include <sstream> | |
| #include <string> | |
| using namespace std; | |
| /* implement your Queue class here */ | |
| //////////////////////////////////////////////////////////////////////// | |
| #define TIMEDELAY 3 //DO NOT CHANGE THIS VALUE!!! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include <fstream> | |
| #include <sstream> | |
| #include <string> | |
| #include <stdexcept> | |
| #include <iterator> | |
| class FileReader | |
| { | |
| public: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using System.Linq.Expressions; | |
| using System.Text; | |
| using System.Threading.Tasks; | |
| using Microsoft.VisualBasic.FileIO; | |
| namespace JuestForCshap | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using System.Linq.Expressions; | |
| using System.Text; | |
| using System.Threading.Tasks; | |
| using System.IO; | |
| namespace JuestForCshap | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import unittest | |
| # Here's our "unit". | |
| def IsOdd(n): | |
| return n % 2 == 1 | |
| # Here's our "unit tests". | |
| class IsOddTests(unittest.TestCase): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| CREATE TABLE OFFICE ( | |
| OFF_ID NUMBER NOT NULL, | |
| OFF_ADDR varchar2(20) NOT NULL, | |
| OFF_NAME varchar2(10) NOT NULL, | |
| PRIMARY KEY (OFF_ID)); | |
| CREATE TABLE EMPLOYEE ( | |
| EMP_ID NUMBER NOT NULL, | |
| EMP_FNAME varchar2(20) NOT NULL, | |
| EMP_LNAME varchar2(20) NOT NULL, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include "algorithm.h" | |
| #include <cstring> // memset | |
| using namespace std; | |
| /*************************** global variables *****************************/ | |
| #define MAX_POSSIBILITY 362880 | |
| enum Direction{LEFT, RIGHT, UP, DOWN}; | |
| bool VisitedList[MAX_POSSIBILITY]; | |
| bool ExpandedList[MAX_POSSIBILITY]; | |
| bool IsExistInQueue[MAX_POSSIBILITY]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 1.upto(100){ |n| puts n%3 == 0 ? "face" : n } |