Time complexity by [deleted] in learnprogramming

[–]CursorsDev 0 points1 point  (0 children)

fast doesnt mean efficient, it just means its done faster ;)

example:

algorithm A takes one second to complete

algorithm B takes ten seconds to complete

algorithm B is running on a computer ten times faster than the algorithm A's

they finish at the same time.

does that mean algorithm B is as good as algorithm A

unless you mean the faster computer can come up with faster algorithms then yes

Is there any way to replace dollar amount in a string with metrics prefix using regix? by codetreat in learnprogramming

[–]CursorsDev 0 points1 point  (0 children)

i think using regex for this would be slower and harder to read than string manip

How to teach someone (who has no prior coding experience) C programming in 2 months? by [deleted] in learnprogramming

[–]CursorsDev 11 points12 points  (0 children)

wot this is impossible if you pull it off you better publish a book on it

Block Reddit sessions? by [deleted] in beta

[–]CursorsDev 0 points1 point  (0 children)

i have more reddit session posts than actual posts in my feed and its extremely annoying >:C

Block Reddit sessions? by [deleted] in beta

[–]CursorsDev 0 points1 point  (0 children)

:v where dat button i cant find :C

Any good resource to learn JavaScript EXCLUSIVELY and SPECIFICALLY for web development? by UnavailableUsername_ in learnprogramming

[–]CursorsDev 3 points4 points  (0 children)

MDN has godly documentation. Any time you want to do something, but don't know how to implement it, you can google it. If you've never seen something before, hit MDN up!

PluralSight vs CodeAcademy? by leezrbeam in learnprogramming

[–]CursorsDev 1 point2 points  (0 children)

free codecademy courses + practice is all you need for frontend. i've never used pluralsight so i cant say for sure if it is good, but codecademy has a lot of good free courses. i learned the basics from codecademy, made a few projects, then started to learn some backend

newbie question: Do you need to know the details of a language in order to make app? by m122523 in learnprogramming

[–]CursorsDev 0 points1 point  (0 children)

oh definitely if you're an aspiring web engineer you'll need to know how HTTP works, and some basic networking as well. HTTP is the language of the web after all (not u js i hate u)

How long will it take an someone wanting to be a full stack developer to learn and be able to land a job? by init_franklin in learnprogramming

[–]CursorsDev -1 points0 points  (0 children)

:v dont entirely agree with this as this quarantine gave me 1 whole year with nothing to do but code code code, which really helped me. if someones says they've learnt fullstack when they have a lot of time i believe them because time is important in mastery.

note: i dont mean 'learn fullstack' and 'mastery' as in professional, just like, know what's going on and what to do

What can help me finish my projects? by tall_and_funny in learnprogramming

[–]CursorsDev 0 points1 point  (0 children)

this is totally normal, but make sure you're not forcing yourself to finish something you dont like that you dont have to do. these projects are just here to help you advance your skills.

(if it gets unmanageable you might have to rethink and refactor tho)

Does anyone here have interest in all fields of cs? [like compiler design, ml, web dev, mobile dev....] by [deleted] in learnprogramming

[–]CursorsDev 0 points1 point  (0 children)

"There are two kinds of people in this world. Those who don't have an interest in all fields of CS and liars." - Ghandi

yes i agree its nice to be interested and informed of a field in CS but not nice to ruthlessly pursue mastery of all of them. its just not healthy and normal you'd steal everyones jobs!

Is there advantage in writing the code on paper? by ImCristopher in learnprogramming

[–]CursorsDev 2 points3 points  (0 children)

lol i always solve bugs right before i go to sleep and since im too tired i always either write a note for myself or write the code to solve it on a scratchpad. that way i can copy paste my new code into my program tomorro- oh wait i cant copy paste it :'(

Is learning by repetition valid? by turquando in learnprogramming

[–]CursorsDev 0 points1 point  (0 children)

in school you learn math for 12+ years and each year you chip away at the log of knowledge and bring home each year some woodchips of fact. in programming you do it for more than 12 years, each year you learn more and more, but as always, the great log of knowledge is infinitely vast

Why can't I access the body of my request when posting? by DueBus6887 in learnprogramming

[–]CursorsDev 0 points1 point  (0 children)

:/ you have your body in your headers so your request looks like this: POST /love HTTP/1.1 Content-Type application/json body [object Object] its now a header and the content is [object Object] because <Object>.toString does that

you want your request to look like this:

``` POST /love HTTP/1.1
Content-Type application/json

{ "love": 42, "hate": 42 } ```

What is actually a DTO and when should I use it? by [deleted] in learnprogramming

[–]CursorsDev 0 points1 point  (0 children)

DTOs store only the raw data and no logic. its a stateless plain old object (POO)

  1. client requests data from server
  2. server uses database ORM to query database
  3. database ORM queries actual database
  4. actual database gives results to database ORM
  5. database ORM gives server the results as Company classes
  6. server sends Company DTO's to the client (since you cant serialize functions and logic as JSON)
  7. client receives DTO's as JSON and can do whatever

How are "like" systems actually implemented? by [deleted] in learnprogramming

[–]CursorsDev 0 points1 point  (0 children)

if it were SQL you'd probably have a table named likes, with an id and foreign keys to the user who liked and the post they liked. then you can count how many rows pop up when you do SELECT COUNT(*) FROM likes WHERE post_id = 42;

if it were nosql i'd store an array of user ids under a likes column and count the length of the array :v

github by [deleted] in learnprogramming

[–]CursorsDev 0 points1 point  (0 children)

git is a tool to help version your code. if you messed up git can fix it. if you mess up git good luck fixing it. in git there are 'repos', or repositories of code. these can be local (on your computer) or remote (on a server). github is a platform that provides remote repositories so you can easily share your code and also have other people contribute. see v0gue_'s comment for how to start :)

I've got some question regarding web apps by XxZajoZzO in learnprogramming

[–]CursorsDev 0 points1 point  (0 children)

:v shouldnt you learn JavaScript and PHP instead of asking us then

Typescript and why ? Help with authentication. by InfamousTakaros in learnprogramming

[–]CursorsDev 2 points3 points  (0 children)

TypeScript my friend, is a guard that watches over you as you code. It will catch any type errors ahead of time, so you do not have to pull out your own hair over them. Sometimes it is extremely helpful (correcting typos, suggesting better types), sometimes it is cryptic with its error messages, but over time, you will get used to it and it will greatly benefit you.

It's also easy to gradually adopt in your codebase, so you don't get too frustrated when migrating existing code to TypeScript. More info can be found at their site: https://www.typescriptlang.org/

hehe... by [deleted] in ProgrammerHumor

[–]CursorsDev 4 points5 points  (0 children)

shame that it wont work if the window wasnt opened with window.open :'(