Giter Club home page Giter Club logo

Rageeni Sah's Projects

queen-s-position icon queen-s-position

This is python code to find all moves that a queen can take from position (p,q) on a chess board.

superreducedstring icon superreducedstring

Steve has a string, , consisting of lowercase English alphabetic letters. In one operation, he can delete any pair of adjacent letters with same value. For example, string "aabcc" would become either "aab" or "bcc" after operation. Steve wants to reduce as much as possible. To do this, he will repeat the above operation as many times as it can be performed. Help Steve out by finding and printing 's non-reducible form! Note: If the final string is empty, print Empty String . Input Format A single string, . Constraints Output Format If the final string is empty, print Empty String; otherwise, print the final non-reducible string. Sample Input 0 aaabccddd Sample Output 0 abd Sample Case 0 Steve can perform the following sequence of operations to get the final string: aaabccddd → abccddd abccddd → abddd abddd → abd Thus, we print abd. Sample Input 1 baab Sample Output 1 Empty String Explanation 1 Steve can perform the following sequence of operations to get the final string: baab → bb bb → Empty String Thus, we print Empty String. Sample Input 2 aa Sample Output 2 Empty String

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.