-
Notifications
You must be signed in to change notification settings - Fork 30
add CS basics answers #108
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
graslowsnail
wants to merge
1
commit into
fractal-nyc:main
Choose a base branch
from
graslowsnail:pabloR/cs-basics
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,89 @@ | ||||||
| ## Computer Science – Basics | ||||||
|
|
||||||
| ### Questions | ||||||
|
|
||||||
| 1. What is data? | ||||||
|
|
||||||
| answer1.) | ||||||
| Data is information that an application uses to do things — like show content, make decisions, or store user input. | ||||||
|
|
||||||
| 2. What is an algorithm? | ||||||
|
|
||||||
| answer2.) | ||||||
| An algorithm is a set of instructions that tells a computer how to do a specific task and get a specific outcome. | ||||||
|
|
||||||
| 3. What is a function? | ||||||
|
|
||||||
| answer3.) | ||||||
| A function is a block of reusable code that does a specific task. | ||||||
| You can call it whenever you need that task done. | ||||||
|
|
||||||
| 4. What is function scope? What is a block scope? What is global scope? | ||||||
|
|
||||||
| answer4.) | ||||||
| - Function scope: Variables declared in a function only work inside that function. | ||||||
| - Block scope: Variables in blocks like if statements or for loops, only work inside that block. | ||||||
| - Global scope: Variables declared outside any function or block, they can be used anywhere in the file. | ||||||
|
|
||||||
| 5. What is a variable? | ||||||
|
|
||||||
| answer5.) | ||||||
| A variable is a renameable container that you can assign values and data to. | ||||||
|
|
||||||
| 6. What is a data type? | ||||||
|
|
||||||
| answer6.) | ||||||
| A data type is a specific kind of data like a number, string, or character. | ||||||
|
|
||||||
|
|
||||||
| 7. What is a data structure? What are some examples? | ||||||
|
|
||||||
| answer7.) | ||||||
| A data structure is a way to store a list of data in an organized container. | ||||||
| ex. arrays, objects, stacks queues | ||||||
|
|
||||||
|
|
||||||
| 8. What is a web server? | ||||||
|
|
||||||
| answer8.) | ||||||
| A web server is a computer connected to the internet that listens for requests and responds with data. | ||||||
|
|
||||||
| 9. What is an operator? | ||||||
|
|
||||||
| answer9.) | ||||||
| An operator is a symbol used to compare or manipulate variables in a programming language. | ||||||
| ex. ++ adds 1 , || OR, === equal value and type | ||||||
|
|
||||||
| 10. What is a character? A string? | ||||||
|
|
||||||
| answer10.) | ||||||
| A character is a single value like a, b, c, 1, 2, or 3. | ||||||
| A string is a combination of characters, like a word or sentence. | ||||||
|
|
||||||
| 11. What is state? Why is it important? | ||||||
|
|
||||||
| answer11.) | ||||||
| State is the current condition or setup of an application. | ||||||
| It’s important because your apps often need to do things based on certain factors or user actions, like clicks, inputs, or data changes. | ||||||
|
|
||||||
| 12. What is an interface? | ||||||
|
|
||||||
| answer12.) | ||||||
| An interface is a way for the user to interact with an app or program. it can be a GUI, or text based like the CLI | ||||||
|
|
||||||
| 13. What is an API? | ||||||
|
|
||||||
| answer13.) | ||||||
| An API - Application Programming Interface, lets servers and apps talk to each other and exchange data. | ||||||
|
|
||||||
| ### Advanced | ||||||
|
|
||||||
| 14. What are calculations (e.g. “pure functions”)? | ||||||
|
|
||||||
| answer14.) | ||||||
| idk ngl | ||||||
|
|
||||||
| 15. What are actions (e.g. “side-effectful functions”)? | ||||||
|
|
||||||
| answer15.) | ||||||
| idk ngl lol | ||||||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Replace 'idk ngl lol' with a detailed, professional explanation of side-effectful functions.
Suggested change
|
||||||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Replace placeholder 'idk ngl' with a formal explanation of pure functions.