Coder Social home page Coder Social logo

zacharyrperales / hackerrank_c_solutions Goto Github PK

View Code? Open in Web Editor NEW
2.0 1.0 0.0 42 KB

HackerRank C Challenge Solutions

Home Page: https://www.hackerrank.com/domains/c

License: MIT License

C 100.00%
c challenge guide tutorial challenges guides hackerrank hackerrank-c hackerrank-c-solutions hackerrank-challenges

hackerrank_c_solutions's People

Contributors

zacharyrperales avatar

Stargazers

 avatar

Watchers

 avatar

hackerrank_c_solutions's Issues

Check if Asserts and Unit Tests Can Assist in Solution

The memory management portion of this problem is difficult to fully comprehend and solve. Assert statements and unit tests may assist in narrowing the scope of the entire challenge to just the send_all_acceptable_packages function temporarily so that memory management solutions can be explored and more closely examined.

Refactor Unit Tests and Cover All Scenarios

The preliminary unit tests do not follow best coding practices.

  1. There is repeated code that needs to be refactored into reusable units.
  2. Only one scenario is covered for the send_all_acceptable_packages function. All logical scenarios should be covered for full coverage.

Memory Can't be Traced After Reallocating and Moving Memory

Instead of a pointer to the first element of the array being stored for the source and target office package arrays as they initially contain, which would be in the heap(?), in the send_all_acceptable_packages function, those values become NULL in the debugger after reallocating and moving memory in the aforementioned function. I believe that this is due to the newly created moved memory being stored on the stack and therefore not being accessible to the debugger or something to that effect. This does not appear to affect program operations but it's not ideal.

This process needs to be clarified and/or resolved.

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.