{"id":13492809,"url":"https://github.com/cs50/libcs50","last_synced_at":"2025-05-15T04:00:26.251Z","repository":{"id":39635891,"uuid":"5053738","full_name":"cs50/libcs50","owner":"cs50","description":"This is CS50's Library for C.","archived":false,"fork":false,"pushed_at":"2024-06-22T22:39:10.000Z","size":307,"stargazers_count":1879,"open_issues_count":37,"forks_count":872,"subscribers_count":150,"default_branch":"main","last_synced_at":"2025-04-11T14:19:36.314Z","etag":null,"topics":["c"],"latest_commit_sha":null,"homepage":"https://cs50.readthedocs.io/libraries/cs50/c/","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cs50.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2012-07-15T05:02:21.000Z","updated_at":"2025-04-09T03:20:04.000Z","dependencies_parsed_at":"2024-01-16T09:17:57.905Z","dependency_job_id":"1603abde-d5b5-41a6-8476-d09e2bff4542","html_url":"https://github.com/cs50/libcs50","commit_stats":null,"previous_names":[],"tags_count":26,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cs50%2Flibcs50","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cs50%2Flibcs50/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cs50%2Flibcs50/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cs50%2Flibcs50/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cs50","download_url":"https://codeload.github.com/cs50/libcs50/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254270640,"owners_count":22042858,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["c"],"created_at":"2024-07-31T19:01:09.392Z","updated_at":"2025-05-15T04:00:26.209Z","avatar_url":"https://github.com/cs50.png","language":"C","readme":"# CS50 Library for C\n\n[![Build Status](https://travis-ci.org/cs50/libcs50.svg?branch=master)](https://travis-ci.org/cs50/libcs50)\n\n## Development\n\n`make`: builds dynamic library\n\n`make deb`: builds source deb\n\n`make install`: installs the library under `/usr/local` by default (set `DESTDIR` to change that)\n\n## Installation\n\n### Ubuntu\n\n```\n$ curl -s https://packagecloud.io/install/repositories/cs50/repo/script.deb.sh | sudo bash\n$ sudo apt-get install libcs50\n```\n\n### Fedora\n\n```\n$ curl -s https://packagecloud.io/install/repositories/cs50/repo/script.rpm.sh | sudo bash\n$ yum install libcs50\n```\n\n### From Source (Linux and Mac)\n\n1. Download the latest release from https://github.com/cs50/libcs50/releases\n1. Extract `libcs50-*.*`\n1. `cd libcs50-*`\n1. `sudo make install`\n\nBy default, we install to `/usr/local`. If you'd like to change the installation location, run\n`sudo DESTDIR=/path/to/install make install` as desired.\n\n## Troubleshooting\n1. If, when compiling a program, you see `/usr/bin/ld: cannot find -lcs50`:\nAdd `export LIBRARY_PATH=/usr/local/lib` to your `.bashrc`.\n1. If, when compiling a program, you see `fatal error: 'cs50.h' file not found`:\nAdd `export C_INCLUDE_PATH=/usr/local/include` to your `.bashrc`.\n1. If, when executing a program, you see `error while loading shared libraries: libcs50.so.8: cannot open shared object file: No such file or directory`:\nAdd `export LD_LIBRARY_PATH=/usr/local/lib` to your `.bashrc`.\n\nClose and reopen any terminal windows.\n\n## Usage\n\nLink with `-lcs50`.\n\n    #include \u003ccs50.h\u003e\n\n    ...\n    char c = get_char(\"Prompt: \");\n    double d = get_double(\"Prompt: \");\n    float f = get_float(\"Prompt: \");\n    int i = get_int(\"Prompt: \");\n    long l = get_long(\"Prompt: \");\n    string s = get_string(\"Prompt: \");\n\n    // deprecated as of fall 2017\n    long long ll = get_long_long(\"Prompt: \");\n\n## Documentation\n\nSee `man get_*` after installation, or [CS50 Reference](https://reference.cs50.net/cs50/)!\n\n## TODO\n\n*   Add tests.\n\n## Contributors\n\n*   [Chad Sharp](https://github.com/crossroads1112)\n*   [Emrul Hasan Zawad](https://github.com/ehzShelter)\n*   [Ivan Jasenov](https://github.com/IvanJasenov)\n*   [Kareem Zidane](https://github.com/kzidane)\n","funding_links":[],"categories":["C"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcs50%2Flibcs50","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcs50%2Flibcs50","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcs50%2Flibcs50/lists"}