#tech-related-help
1 messages ยท Page 24 of 1
Hi, someone who know about java, to help me in a school proyect
for if statements theya re the same, but for while monka
wait i think i sent you wrong screenshots when i tried it
i had the console.log() before it adds 2 for the while
that would mean that the while loop in JS does not require an iteration statement
hmm
forget what i said, that was a stupid comment lmao
var x = 0;
while(x < 12) {
console.log(x);
x = x + 2;
};
//output 12
js in a nutshell
is 12 < 12
it isnt
int x = 0;
while(x < 12) {
std::cout << x << std::endl;
x = x + 2;
};
//output 10
wait i retract my earlier statement
๐
looking from a different angle
i cant see it any different than JS while loops initalize first
c++ while loops check first
i mean cant see it any different rn
since it prints it in the console first. imagine that it just printed x=12. it should then add 2 to 12 making it 14 but it shouldnt print 14 anymore since going back to the top of the while loop 14 > 12
im walking away from the problem now
i cant get stuck for another hour i dont want to hehe
thankyou for taking the time out of your day
no my mental block is strong hehe i dont get it
i agree with c++
bc im like you are comparing left side with the right side
wait what
๐คฏ
i think it just prints out that 14
for some reason
yeah its just the browser console that i was using
when i do it here its only up to 12 but in the console it shows 14 but with that arrow
but why were you getting 14
i am using replit
it shows up to 12 only
it should be 12
yes the ide on mdn web docs its 12
we should have talked about this in a thread ๐
in the dev tools
its 14
yes i regret not doing it now ๐ข
problem solved it guess
I'm working on a dynamic website and am having some issues
so i have an insert.php file
but it comes up with this error on my localhost
and idk how to fix it
Are you allowed to have a space before a semicolon in php?
yes
Is there someone who knows how to help me in cisco packet tracer ? ๐ข
yo anyone good with graphs and wants to help me understand a few algorithms better
im having trouble finding all possible cycles within an undirected graph that runs in O(|V| + |E|) and that I can understand lool
I know that you can detect that a graph has a cycle by running bfs on each node and seeing if you encounter another 'flagged' node while bfs is still running but i dont think this would help in any way
I know this was a while ago, but Javascript is asynchronous, meaning code doesn't execute in the order you write it, like C++, but it will execute multiple statements at the same time, and x being incremented executes faster than the print. Take a look into the await/async funcs
Ive also found this article that talks about smth called johnsons algorithm but i cant understadn it for the life of me, heres the article (https://www.cs.tufts.edu/comp/150GA/homeworks/hw1/Johnson 75.PDF)
and the issue is I dont even know if johnsons algorithm can apply to undirected graphs :/
thankyou this is a great answer, i am not that far into JS but i wrote it down that when i come there i will pay extra attention to this
seems sus, i wouldn't trust this ^
it's a scam link
<@&717391911132069929> can you delete the link and kick the dude?
every "giveaway" scam looks like that
can someone please help me im having a mental breakdown ive to code this stupid button in python and its supposed to open something and I cant im about to drop out
could someone tell me whats wrong with this code
you need to tell us what's the expected behaviour
and what's the actual behaviour
also error logs if there are any
"What's wrong" is very vague
im trying to swap the words in the spans
but when i try the console says it cant read the properties of the .innerHTML
Selected is always null. it is not initialise anywherr
I instead of selected==0 do selected==null
thank youuuu
what's the language?
This look like ubuntu๐ค...or maybe I'm just stupid๐ I'm really not sure
Ignore what I just said...it's probably wrong anyway
i think its Delphi
searching stuff on the internet and came across this
ah yes, ubuntu the language xD
Does anybody know LU decomposition (linear algebra)? https://en.wikipedia.org/wiki/LU_decomposition
I have to program it and answer some questions, but I don't understand the questions
In numerical analysis and linear algebra, lowerโupper (LU) decomposition or factorization factors a matrix as the product of a lower triangular matrix and an upper triangular matrix. The product sometimes includes a permutation matrix as well. LU decomposition can be viewed as the matrix form of Gaussian elimination. Computers usually solve squa...
89 is my best wpm in monkeytype what are yall best
99 (: -> 103
first time using monkeytype i like the visuals
ive been using 10fastfingers
lemme grow another hand to beat that score
is anyone here familiar with synthetic data generation?
Can someone help me with smarty/php ???
does anyone know how to learn about gpu construction and how to modify gpu's bios?
nowadays most video card firmware is digitally signed
I dont think you cant mess with it like you want
You can however learn about it's construction yeah
I recomend looking at wikipedia articles since they usually start from the beginning of graphic cards, and it's easier to follow
You can program your GPU tho, but i don't think that's what you meant
You have langs for that, like CUDA and OpenCL
Thanks for help
Is this chat also for theoretical CS?
This is Delphi, because APPTYPE CONSOOLE is only used in Delphi. Also funny to see Russian comments in the code
I need help with these. using c++ stdio.h
can someone help me with some simple codes? i'm new and i'm really confused๐ฅบ ๐ญ
What's the problem
first of all, why are you using a C lib for standard input and outpu?
#include <iostream>
This is the one you want for standard IO in C++
Second, you will need access to the math lib
because you will need the square function and the root function
sschool work
Still, doens't make sense to use C libs on C++ (unless that are no other alternatives)
#include <cmath>
This is the lib for math related function and constant values
the functions you are looking for are std::pow() and std::sqrt()
If you have any trouble using them just post here your question and we'll help, but they are pretty straight forward to use
thanks thou. big help
Yep should be
Can anybody which languages required for game development
it depends entirely on what you want to create, youll have to see what programming language fits your needs
just a couple of examples (not going in-depth):
2d - python: python syntax is close to pseudo code making it easier to learn, plus it has the pygame library which is the most used 2d game making library in python. its popularity makes it easier to learn and solve problems.
-c#: c# can be used in the unity engine to create simple 2d games, the use of an engine is that it gives you a ton of features to work with. the unity community has a lot of tutorials and solutions so it is really and has a less steeper learning curve
3d - c++: c++ is a powerful low level language that communicates with the hardware with almost full capability. this makes games developed in it way faster although the low level aspect gives it a bigger learning curve (harder to learn). you can use the OpenGL library to communicate with your GPU to render stuff on the scree.
-c#: again, c# can be used to create 3d games in unity, with a ton of tutorial and a lot of help, learning unity "should" be pretty easy although i havent tried it so i cant give my full opinion on it
there are other programming languages that you can use such as java or javascript but i cant write about them as i dont have enough info about them (you could def research though!).
i hope this guides you in anyways and looking forward to see what you create!
C# is widely used because of all the stuff thats available for it
is there anyone who know matlab for numerical method. I need some help for function commend
hey i wanna make an app, ik react and i heard react native was easy to learn, but i was wondering what backend i should use or if theres one that works well with react native
I saw online that ppl said to use firebase?? but ive never used it as a backend framework so idk lol and suggestions
the app is gonna be simple i just need to have like login, store some images, text thats all lool
this is cool and im so enjoying my life.
high
Hey!
My uni offers me 2 courses as electives -
- Internet of Things
- Quantitative Analysis
Can someone help me get a better idea about these subjects?
Thanks in advance!
wouldn't your uni have a course description of what you will be learning and exploring?
This
Yea we've been give the syllabus and course outcomes for the same, but I'm still kinda confused :/
Like quantitative analysis is mostly stats and will be helpful if one's into data science
And IoT well you get to know more about hardware ig
I mainly want to know which one has greater scope in cs field or are they equally good..
They are both quite useful in different fields
It depends on your domains of interest, which one you go for
Yes yes, I'll look into these subjects in detail, thanks for helping :)
Unless you're game dev'ing for XBox, I would stay away from C# honestly
I wouldn't consider game dev till you are taught the basics of OOP @fresh solstice
Else it will be kinda annoying
And if you are a beginner I would stay away from C++, C++ is not a language you just pick up and start game dev'ing in, it's really hard to grasp expecially when you are starting with such an advanced topic as game dev'ing
Python i think would be a nice starting point
Maybe look into the Unreal Engine, i think they have a script lang
UnrealScript yeah
Or Java maybe, but again OOP principles are a must in my opinion
By the way, tell one thing is app development easy or gaming Development
i dont understand what youre saying?
i listed some methods of game dev although some of these ways are hard and require you to create from scratch
Thank you actually i am beginner .
Okk.
Are you a beginner in programming?
Yes I am beginner
Maybe stay away from game dev'ing till you learn a bit more of what exactly is programming
Start small
you shouldnt really learn c++, it has a much higher learning curve.
Make small stuff, learn slow
Don't rush into a big things like game dev, in my opinion
Take your time learning the basics of programming first
i wouldnt exactly say not to game dev, unless you dont know any of the basics such as OOP or arrays and such, you can make little 2d games. but you also should consider not creating big projects, work on what you are capable of
You could, except he's new to programming
like 0% new?
Unless you're talking about Scratch, I would advice against starting like that
what should i start first which language
im not talking abt scratch but creating simple games would be a good learning experience, unless he is a total beginner just as you said
as i said before, it depends on what you want to create
Do you have any experience with programming?
Have you ever programmed annything?
At all?
NO
You shouldn't even be thinking about game deving then : )
yeah you really shouldnt at this stage, pick up a PL and start learning the basics. you will get to learning game dev then
Are you a self learner?
Or do you have programming classes?
Actually, go to a library
Okk thank you .if i start with the phyton
Ya i am self learner .
actually i have nothing to say, this is the best thing you could get.
pick a PL, get a book for it and start learning
If I take Udemy Course
if you learn better from a udemy course, sure.
but i dont really know about the course youre choosing
Okk thank you ๐ค
(a book is better than a course tho but np)
The reason why I'm more inclined for you to get a book is to force the habit of reading. If you want to be good at anything you will need to read
You will need to read documentation, hardware details, github projects, code, etc
Alot of people lack that
plus books just give you more freedom and some times (depending on the book), gives you more detail.
The major problem with books is that once they are printed, you can't update what on the book
So alot of books that are printed stay deprecated as time goes by
Unless we are talking about like C or old languages
But usually for a beginner that's not really an issue
still, even if the book is old, it provides a ton of information (Although yeah books may go too old)
Yeah, i'd still recommend a book, making people read is important
But also practise
Try to learn by try and error while you read
And don't be sad if you get errors
Every one get's errors
Errors are a regular occurrence in a programmer's life
Even the experts get errors, the only difference is that errors from experts usually can only be solved by other experts X)
yall does anyone know some good cs courses on udemy or coursera or something?
im in 2nd year and feeling unproductive af need help
if youโre interested in data science, iโve heard data camp is good
is that on udemy?
nah itโs a different website with coding courses for python and r and stuff like that
ohh okay
Which particular field?
Or general computer science?
Im looking for machine learning ai and data science stuff
Ah okay, I'm not acquainted with that field but I've heard praise for Andrew Ng courses
anyone here knows about a university its free like uofpeople teach aerospace engineering?
I found another free university for masters in finance in engineering but not for aerospace or civil or electrical engineer.
i need to write a program in c that receives a string, corresponding to a mathematical formula, and prints out the result
im 3 weeks behind in my class, any type of help would be great
is there anyone who knows how to use matlab
A little bit
But I only use Octave
What have you tried so far?
yea lol send ur code
Is anyone here really experienced with PHP and JavaScript? I need help practicing for an interview
id say leetcode is ur friend here lol
guys guys what is this? it's in the upper-left of my screen?
press esc
might go away
I'll show you how to get rid of that annoying white box that pops up in the top left corner of your screen. Like, Comment, Subscribe, Don't Hate.
maybe?
heyy if i go for an internship in c++ what skills do i need ๐ฆ
I want to do an internship soon to get more work experience
and if i follow software, is c++ ok?
-- i'm bad at english so i use google translate
TakeRep <User:User> [Num:Whole number]
Invalid arguments provided: Did you mean one of these? (I'm 1/5, I'm a Nacho, I'm back, i'm bored, I'm Cat) Please re-run the command with a narrower search, mention or ID
[python] does anyone have an idea how to code an array of linked lists? conceptually, it looks like this:
Can anyone tell that best course in web development in Udemy. in which to get a good structure
Hi! i'm new here, here's a list of computer science courses for everyone stuck finding resources https://github.com/Developer-Y/cs-video-courses
Very interesting, might take a look at it later
wassup guys, just wanted a little help with creating a comand line program in C++ which tells the day you're born ( given date of birth) , thnx;
please elaborate on where you need help. possibly show code on what you have so far, etc.
Does anyone know where I can create a website easily? I'm supposed to code it but I don't know anything about coding
There is a bunch of different websites that you can use to create an online website. It really depends on to what extent you want it to look good. Also, if you are expected to code it you are going to have a tough job getting away with a nicely formatted pre-made sight that you just drag and drop things onto.
- Something to just consider?
I am gonna be talkinf computer architechure next sem. Anyone take it yet and let me know what is the most difficult part about it.
Working with Assembly is difficult at first but once you get enough practice it becomes pretty simple honestly.
I am learning MIPS RN.
I am almost done with it.
It is kinda cool learning about some of the components of the CPU and how the registers hold and store info.
anyone any good with C?
This is weird, I just bought a T60 off Facebook Marketplace and it has a glossy screen, wasn't until I got home, I've realised it looks like a screen protector?
not too sure though
flash light it
you would be able to see the difference
I went for it and it was, well it came off so ๐คทโโ๏ธ, now just glue residue time
I am deciding between choosing ipad m1 11' and 12.9' . 12.9' more than 11' $300 but only better at the screen. if i select 12.9' and paste paperlike on it, will the display quality drop much? if it's a lot, I should choose the 11' version right? please advise me which one to choose and type paperlike i should use
hi i need some help , In a system, which uses an ASCII code of 8-bits, how many pages one can store in hard disk space of 760 Mbytes. Suppose that each page contains 2000 characters.
-but ASCII only do about 256 characters i guess right ? ๐ฅฒ
thank u
I have the 12.9 version but one of the older version right before m1 chip came out. I also have it with the paperlike screen protector. If you are going to be using the iPad for school then paperlike in my opinion is a must have amenity. If you are just using it for leisure then honestly any amazon screen protector will be fine.
The paperlike screen protector does not impact the display quality at all. It is truly just an amenity that makes looking at the iPad easier and increases the feel of the iPad when using it for writing.
if you got a question just ask.
don't say "is anyone any good with C"
it's like saying "is there any expert around to help me out with my code"
For some reason i decided to open and no regrets ahah it makes a valid point tho
๐คทโโ๏ธ
actually sometimes i dnt answer people when they make those sort of questions cause idk if i will be really able to help or not so yeah good advice people make ur questions clear
it's like this everywhere, instead of asking the question they asking for "experts" to help them, even a beginner can help if they actually read what the problem is
exactly
yeah
I always feel like posting this here but I abstain cause it might be rude and because mostly people won't see it anyway :))
well i had never seen that before but it makes a lot of sense i think everyone should read it tbh
in this case for him no one replied, ofc no one did no one is gonna call themselves an expert when they don't really know what the issue is
yeah
it's not rude, if they read it in a rude way that's a them problem not mine
im just dropping it there so they can learn something ๐คทโโ๏ธ
im actually helping if you think about it ๐
well dnt get me wrong but do u know the answer to my question in maths by any chance?
Apart from that, people often post questions without the relevant data associated with it
no sorry i can't help you with that
Like a screenshot of code and then "what's wrong with it" ๐
thx anyway!
or they give you a log with 500 lines in it asking you to solve it for them
people should be specific when they ask question, when you ask a question you should give all the information needed for someone to help you out, you can't just say "help me with this"... What does the error say for example
it abt computer system. like the components and its relation. its quite not easy cause its smth we dont see. its how computer work inside and stuff but once u grasp the concept, you'll be fine. it just full of theory to remember โค๏ธ
exactly what im saying ๐
yeah sure i'll just send my 300 lines of code to someone and make him read all that and see where the problem is like... just tell me where is the problem ๐
people doing that are making others life harder doing this..
I mean, people just won't reply to that message for help
actually, there's gotta be an error in the terminal, else if there is no error then it's fine ๐คทโโ๏ธ
No one wants to go through lines of code to find an arbitrary problem
no one wants to go over 100 lines of code just to find a typo
like me yesterday spending my whole day in 500 lines of code just to find out i did a typo...
pain
well im sorry to bother u guys but seems like u two both know a lot about coding do u have any tips on how to understand loops? im having a hard time deciding whether i should use while or do... while in c sharp. Totally fine if u dnt
yeah not the best dude to ask for maths ๐ and imo you should ask in #math-help incase you didn't and if you did then i guess go try on https://mathpapa.com
got the perfect vid for you
i'll send it
i did ask there but no one actually answered and im here with the book opened waiting for a generous soul to help me ahahah
Basically is about wether you want your code to be executed first and then make the decision or vice versa
๐คฃ
thx its hard to apply in exercises tho
what she is asking is when and what should be used for specific stuff
thank youu!
I cannot send such a huge text, sry
that's why im sending a video instead ๐คทโโ๏ธ
just tried they dnt know how to solve the inequality thx tho
totally fine! thx anyway
there are a bunch of other websites to help you out with math
im pretty sure you can find other ones that work with a simple google search
u right i will try
just type your problem and you might find it
yeah idk why i didnt think of that tbh mb
no worries (:
Happy learning!
well. do...while is u do first then u loop. if while... u loop first then u print or do stuff
she will understand better with the video im sending
ok thx everyone yall really helpful!
A loop is something that executes a piece of code until a condition is met
So that you don't have to type the same code N times, and if you don't know how many times to run the same piece of code for example
yeah thank you!!
What language btw?
C#
sheesh
U think its hard?
Not at all!
I just dislike it : ) But don't let my experience influence you! Is a nice language for beginners and web stuff
Ah alright!!
Thanks!
C# isn't for web...
hello everyone
Hi
hi
Many others hate it aswell
How's life?
great how are ya
Im good, still breathing yk :)
๐
I have a bit of a boring question, is anyone in this group learning Assembly language?
What?
C# is used for ALOT of web stuff
It's a web language
Inform yourself! ๐
not actually i think, but yeah c# is used many in web
Sure you can use if for non-web things, it's still a web language
I think you misunderstood
Look at the API's for C#
C# can be used for web applications
They are all web oriented
Now for websites, i don't think that's the same
Whatever you say man
Easy to start: C# is a high-level language so it is closer to other popular programming languages like C, C++, and Java and thus becomes easy to learn for anyone. Widely used for developing Desktop and Web Application: C# is widely used for developing web applications and Desktop applications.
now you can code web by any language
well you're not wrong, but at the same time you're not right
if you use frameworks maybe
well im not really sure, but i feel like C# can't be used to make websites
but maybe for web applications
well if you're using some kind of a framework then yes but you can't really build a website without any kind of a framework ๐คทโโ๏ธ
well i think it can be used for web but i im using it for "console"
that's usually how you start yeah
sadly i am still struggling with the exercises even though i understood the theory ๐
What is the excercise?
Well idk c# but im curious
Product of a sequence of real numbers, ending with 0.
i guess it dsnt seem very hard
but i am having a hard time doing it
and so i just delayed studying for tmrw
this is an example
product is multiplication (*)
.
oh np dnt worry!
did you try google about your problem?
i didnt cause idk seems like a very specific problem
but i did some coding
~its just some stuff that is not correct
and idk how to put it
is there an error?
double numero, b=0, multiplicaรงรฃo;
Console.Write("\nNรบmero? ");
numero = Convert.ToDouble(Console.ReadLine());
if (numero == 0)
Console.Write("O produto dos nรบmeros รฉ 0.");
else
{
while (numero != 0)
{
if (numero != 0)
{
b =b+ numero;
multiplicaรงรฃo = 1.0*numero * b;
Console.Write("\nIntroduza um nรบmero: ");
numero = Convert.ToDouble(Console.ReadLine());
}
else
Console.Write("\nO produto dos nรบmeros รฉ: {0}", multiplicaรงรฃo);
}
i put this
but idk where to put the ahh idk how to say it in english, average i thinkk
not average
the multiplication
average was from the previous exercise
i will look at this again tmrw and try to figure it out tho
well i can't see what's wrong
ah the multiplication i think its wrong and it lacks console.write ("The multiplication is equal to...") but i just dnt know where to put it
thx for trying to help tho
i don't think you need to add this 1.0*numero * b
you can just do this instead 1.0 * numero
without the b
oh sorry
1.0 * b
without the numero
the thing is like that wont it just give me the last number i inserted? instead of the multiplication of all the numbers?
you're already adding numero to b so i don't think there is a need to multiply them both again
hmm the thing is suppose i insert the numbers 5 and then 10 i will get b=0+5 and so b=5 then i insert 10 and i will get b=5+10 so b=15 that is different from 10*5 which is 50
What exactly should the program do? Do you just keep entering numbers that will be multiplied until you enter 0?
yes that is it
double new_number = 1;
double product = 1;
while (new_number != 0){
// TODO: Ask for new number with Console.Write
new_number = Convert.ToDouble(Console.ReadLine());
if (new_number != 0)
product = product * new_number;
}
// TODO: Write the product
You can try an approach like this
that looks way more simple thx i will try just a question in case the first number inserted is zero it should probably give a error message, how can i do that? do i put it inside a else under the if inside the while?
sorry if my message is kinda confusing
just tried it is working tysm
Then you need to use an if to check for it.
Instead of double new_number = 1; in the first line, you can replace it with
Console.Write("Enter a number\n");
double new_number = Convert.ToDouble(Console.ReadLine());
if (new_number == 0)
Console.Write("Enter a number other than zero \n");
de nada
thx i will try it
u answered in my language thats cool : )
Can someone help me with a little issue related to arrays in C?
Not sure if anyone answered this already, but you could do a list of Nones, and then use it as an array. Then you should make a Class ListNode for your implementation of the linked list. If you haven't made a linked list in python before, then you should start there. If it is not important that you make the linked list yourself, and just need a list of empty lists, you can do list = [[] for _ in range(8)]
what is the issue?
you should try to express all components as the same base number:
Anyone good with PHP?
Oh wow i would never have remebered that 8 is equal to 7*7โฐ thank you!
You will never get a reply if you don't tell us what your issue is
Anyone knowlegeable about linear programming minimization to help me that has 4 or more constraints. Any help would be appreciated.
Like how Can I plot and find the x and y for finding the optimal solution.
hi, i'm wondering if anyone can download node.js
https://nodejs.org/dist/v16.13.0/node-v16.13.0-x64.msi
it seems like its not working for some reason, my internet connection is good and it seems that node.js is not down
any help or information will be appreciated, thanks :>
it works for me. was there an error when you were downloading? if so what was the error?
did you download the right type? https://nodejs.org/en/download/
Thanks, so the solution for me is that I changed my internet to another provider and it works
i would put the $email=$_POST["email"] as well as $nome above the $sql variable
you are inserting $email into your query without setting its value
i also dont think you need the '' in the VALUES()
I did a new test, apparently the problem is that the PHP code doesn't connect with the Email and Name columns
did you set a db connection in your code?
y
oh is it because you named it NOME?
portuguese
ohhh
do you know what it can be?
OMG I LOVE U
I FUCKING LOVE U
I WAS TRYING TO SOLVE IT FOR 5 HOURS
Oh lol just got back
Np
You doing a cms page?
I would also sanitize and validate user input
Using filter_input()
I'm doing work for my school, I'll polish this site in the future XD
Niceee
Lesson learned tho
but thank you so much, you saved me
YEAH XD
Before you use a variable. You have to first create one and set a value
I thought the order didn't matter xp
it does actually
it's from top to bottom
you can't make a function and print a value that does not exist, you will get undefined, that happens for example if you put the variable below the function
if you put it above it does work (:
this lesson I take to life 'v'
This is the function prototype for strncpy_s():
errno_t strncpy_s(char *restrict dest, rsize_t destsz, const char *restrict src, rsize_t count);
``` Notice how it takes four arguments
anyone can suggest any utube channel or website i can learn java programming?
can someone tell me why the output still blue pleaseee
If, anyone need any SEO help..Ask your question.i'll try to answer your question
Can anyone guide me for which ipad to go for
please elaborate on your preferences, requirements, budget, etc
hi guys, there are any differences between installing openCV if you use VisualStudioCode?
no i think it should just be the same regardless of the ide, but it does depend on langauge, os stuff like that
just search 'install openCV {language} on {os}'
and you should find a tutorial or smth
anyone pretty good at html? tyring to display data from a json file in a text field
I can display it in a text area but not text field for some reason
are you assigning the the json data into the value attribute?
Atm I was using AJAX to retrieve the JSON data by doing this
document.getElementById("bookID").innerHTML = (" " + Obj.books[i]["id"]);
Then in the HTML using id="bookID".
I couldnt get it to work for the text field, but it works for
<textarea id="bookID"
When I try to put anything for value inside of a text field, it'll display whatevers in the "" instead of bookID
are you using both the text area and the text field? if so im pretty you cant have more than one element with the same ID
another possibility is that you should be using .value to assign to a input field
https://stackoverflow.com/questions/7609130/set-the-value-of-an-input-field
i just ran a test on w3schools idk if it helps or not
this is python, why does it come out has 84 and not 44
use elif statements
when u use all if statements like that, they are all being checked one after another meaning one input could be true for multiple if statements, what u want is only one of those statements to be true and then u check the next input
change ur two inner if's to elifs and ur last one to an else and try again
thx
I ended up using text area because text field was not working for me, but text field was preferred.
I will look at this when I am back at my computer, definitely seems like a great help. Ty ty
I'm confused between 64 and 256 gigs ipad 9th gen, I want to use it for note taking, textbooks and watching video lectures and light media consumption
And 256 is way expensive than 64gb
anyone can teach me system analysis and design
Hi
if ur not gonna be using it as like a substitute for a laptop u really dont need 256 gigs lol
64 is perfectly fine for school unless ur like a media major whos gonna make like a terabyte of video content then maybe lol
hey can anyone help me? its in c sharp and i need to ask for a number and then check whether that number is prime or not and return that information to the user but idk how to check if the number is prime, ive tried to search it up but all i find are very complex answers that involved stuff i never talked about in classes, so does anyone know if its possible to check it in a simple way oh and i need to use " while" (the loop) in this exercise. thank you
edit : i found the solution thanks
What was it?
hi, well actually i changed something and i though it was working and i didnt want to waste anyone's time so i said i had fixed it however looking better it is actually not fixed so
I would be looking into modulus operator
use this as a last resort. i would try to figure it out myself first before checking.
thank you! i had tried to do it but i didnt know how to put the conditions
Don't think like that, you're not wasting anyones time, if people were annoyed and didn't wanna waste their time they wouldn't try to help, actually they shouldn't try to help, so don't say that again, if anyone wants to help they will and try to, if not they should not reply and move on with their days
thx for being friendly : )
So if you need help just ask for it and if anyone is willing to good if not then they shouldn't reply ๐คท๐ปโโ๏ธ
No worries :)
So just ask your question and what your problem is and wait for someone to help you, if not there are other places to ask for help aswell, tons of coding servers you can join
alright thank you!
Np
I was using innerHTML when I see now that its .value !! ๐
ayyy glad that it works ๐
yea since most ppl are prob getting this and there was like a black friday deal a shit ton of stuff is on back order
If I have a group of text fields say named 1-5, that I want to edit all at once (toggle on/off the text field)
can I just put them in a div class and make one button that allows that toggle? instead of making an individual button for every text field.
you can still use ID's for them with only 1 button. You will need to create a click event function that gets all 5 ID's. But yes you can use CLASS for them. I would still keep the separate ID's for each text field for any possible features that involves 1 text field.
Can anyone here help with some python?
please help me sign out my microsoft account out of my pc
:(((
idk why my laptop dont have "sign in with a local account instead" session
๐ฆ
how do i convert this into #include <stdio.h>?
using namespace std;
const int SIZE = 9;
int main()
{
int arr[SIZE] = {1, 2, 3, 4, 5, 6, 7, 8, 9};
cout << "Initial array:" << endl;
for (int i = 0; i < SIZE; i ++) cout << arr[i] << " ";
cout << endl;
for (int i = 0; i < SIZE/2; i ++)
{
int temp = arr[i];
arr[i] = arr[SIZE - i - 1];
arr[SIZE - i - 1] = temp;
}
cout << "Final array:" << endl;
for (int i = 0; i < SIZE; i ++) cout << arr[i] << " ";
cout << endl;
cin.get();
return 0;
}```
Hi I am currently stuck at a problem. Can you provides me some ideas
How to calculate sum over all "x^2" of all subsequences of a string. Assume x is the number of occurrences of a subsequence of a string. Example: "banana" : 139
"aaa": 19Hi I am currently stuck at a problem. Can you provides me some ideas
How to calculate sum over all "x^2" of all subsequences of a string. Assume x is the number of occurrences of a subsequence of a string. Example: "banana" : 139
"aaa": 19
Can I ask why you want to do that? stdio is used in C mostly and has less features than iostream, which is made for c++
just replace the cout's with printf's, and the cin's with scanf's
For example
cout << "Initial array:" << endl;
becomes
printf("Initial array:\n");
Read the documentation for printf or scanf, it will explain in detail how to use them
ayo i need someone to teach me computer science for my exam in 2 days
can someone help
yoo I'm bad at it. my prof said convert it into stdio
lol this made me laugh
Bro i am deep shit rn really need someone to teach me
like its impossible to teach u every thing in 2 days and also no one boutta sit here and tutor u lol u can ask questions and we can respond but
yea idk lol
Just a lil bit
Not the whole thing some parts of the chapter
yea like i said just send specific questions here and ppl will help u
but u have to at least try no ones gonna put in effort to help u if ur not trying urself
Am trying i promise
Does anyone know how I can land a good internship position while pursing a BS in Computer Science. Everywhere i've looked it just seems like companies only want graduate students. I have setup a linkedin but havent optimized it to the best of my abilities. Currently I am adjusting to in-person college and trying to start projects to my name. Any tips would help
does anyone have a reliable place where they get pdfs of books? I have a project for one of my uni english courses which i need quotes from my required texts. However I got covid and all of my textbooks were left in my dorm and I am currently quarantined in my hometown ๐ฆ rip my finals week haha definitely one for the books
Please check pinned messages in #845877644599361576
Anyone have vscode on their discord display or is that cheesy haha
I had a lot of trouble finding internships and jobs by just randomly applying. A lot of getting a job is about connections, so try going to job fairs etc on campus and talk to your professors about opportunities. My university had a company that recruits a lot of our students and that is how I got my opportunities.
i have it on. i wouldnt say its cheesy tho ๐
i would go with informational interviews. i recently just learned about them at school and we were able to practice it as a project. It is a good way to connect and learn more about the industry in the area you are interested in. I wouldnt say that doing these will get you jobs directly but it does build your network. if you stand out they might connect you with people they know who they know who has a spot for you.
http://libgen.li/ is my go to
a lot of people have been telling me to learn react. any idea why?
How to guarantee a number is natural in c sharp?
Edit i still dnt know how to do it but no longer need, i though the exercise required it but actually not : )
just check if it's >= 0 i guess?
I dont really think there is a built in functionality for that
you could make a function to check it
bool isNatural(int number)
{
return (num >= 0);
}
I did that but i though i had to make sure the given number wasnt like 2.3 or something but then i asked the teacher and actually it just couldnt be a negative number or zero the question was badly written thi
I havent learned that yet, thats why it got me so stressed but thank you!
anytime ๐
Heyyy anyone good at developing native android apps in kotlin compose? I got a issue
Can i post my stackoverflow question link here? Is it allowed?
can anyone help me with Access 2016? in counting and average
how can I get that image to align with the gomoku title? Gomoku is in header and image in the imghello. I think image link is in header as well.
Wait lmk try real quick
id say
display: flex;
justify-content: center;
Should they not both be in the header or it'd be fine? for good practice
i think it should be under header and you will separate Gomoku and the Image in divs
youll have like a div#id for title and div#id logo
Is there like an HTML call to make a base template. And then just add to it? I remember doing it for Django with python but not sure if that feature is available normally
Whats up
Did you want to work while youre in school? I'm guessing summer internships will start appearing in a couple of months
is someone familar and willing to help me with a simple MLP in pytorch?
can the mods force people to read this before sending messages here somehow lol https://dontasktoask.com/
Hi guys,
I have a Powershell problem, so I have a txt file which contains different values(coordinate,date,count of something) and I'd like to read it line by line and find the maximum "count of something" value, but for some reason the output is not correct. What could I miss? Here's what I wrote so far:
$max = 0
foreach ($data in $file) {
$k1, $k2, $date, $t, $count = $data -split ' '
if ($count -gt $max)
{
$max = $count
$maxk1 = $k1
$maxk2 = $k2
$maxdate = $date
$maxt = $t
}
}
Write-Host "$maxk1 $maxk2 $maxdate $maxt"```
and the file.txt's content has a pattern like this:
`77.9549770, 87.3876472 07.30 18:09 26`
can someone tell me which are the best laptops to buy under 40k INR in india? for a student and a working professional
does anybody now how i can safe my input on my website using (javascript)?
Hp 14 series laptop is best in that range
By safe u mean sanitize?
U can apply in github externship
I can help
Can someone help!! I don't know how to write this in python.
- (HC) Offset encryption is a way of encrypting text so that each character of the text is cyclically moved by n places in the alphabet (English alphabet). Example of encrypting an individual letter for n = 2 (eg letter A => C, B => D, ..., Y => A, Z => B).
Write a program that will enter the text (only capital letters of the English alphabet) and the number n, and print the text that we get by encrypting the input text by encrypting with an offset for the default n.
https://www.geeksforgeeks.org/rot13-cipher/
Refer to this...here they are shifting by 13 just replace that with the user input
thank you so much
Yes
You can use function like this
function sanitize(string) {
const map = {
'&': '&',
'<': '<',
'>': '>',
'"': '"',
"'": ''',
"/": '/',
};
const reg = /[&<>"'/]/ig;
return string.replace(reg, (match)=>(map[match]));
}
It will sanitize all type of malicious code the other person trying to inject
+1
Can anyone tell me how can I fix the thing next to the battery? It's supposed to be like in the 2nd pic
im trying to screen record a vid using windows game bar
but im not able to record the device audio
any tips?
change this to all
in settings
ohk i'll try
done!
arigatou!!
hiii anyone know how to code in c++???
yess
oo can you help me code something??
.
yess i can try. whats that something?
i dmed
does any one knows where can I find classes/videos for programming python for data analysis for finance (like regression)
andrew ng on coursera is good
thanks
Anyone that is good with embedded systems, mainly 8051 assembly programming ?
hi. anyone with nodejs/express routers experience?
yesss
Guys, i am a beginner and i want to learn how to code(python to be specific). Are there any good sites from where i can learn python for free?...there are a lot on the internet but they are just not good enough...thanks
Hey guys I wrote this C++ code for my school work and I don't understand why this one line fix my code http://pastie.org/p/02GQg9Wm2dlvflGR4aSXTJ
the line in question is line 32
freecodecamp is pretty good for python or Just start building a mini toy program you will learn it better that way
This function here should do it like -> ptrPlayer[++x] = p
else it will overflow for last player and cause seg fault
this is asking if the operation (in this case assignment) is done from left to right (left associative) or right to left (right associative).
no problem! good luck!!
who said they are not good enough?
Take online Python courses from top schools and institutions. Learn Python programming to advance your education and career with edX today!
Python tutorial - Python for beginners - Go from Zero to Hero with Python (includes machine learning & web development project).
๐ฅ Want to master Python? Get my Python mastery course: http://bit.ly/35BLHHP
๐ Subscribe for more Python tutorials like this: https://goo.gl/6PYaGF
๐ Watch the new edition: https://youtu.be/kqtD5dpn9C8
๐ Get my FREE ...
thanks brother
guys can some of you help me with c++
how to make cooding from this
i only get the ipo
Write python program to get data items from a list appearing odd number of times
loops and lists problem|
Can any one give me a ideea
Can someone help with this by any chance? I generated the random integer like they asked, but I got no clue how to convert this single value back to a place on the board; how do i attach the values to a place/coordinate on the board?
I do have a snake_list which is a list with the coordinates of the snake (which is also used to calculate the number of available spots on the board)
do anyone know hot to fix this error ""
Access to fetch at 'https://w' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.
Which language should I start with c or c++? I am a complete beginner. I have tried the video for c by freecodecamp.org but they seem to explain very little of what is actually happening. Maybe a book on c might help. Please suggest a book for complete beginner and also verdict on starting with c or c++. Also a youtube channel which has detailed explanation.
is there someone available to help me out in dms
Anyone Familiar with SQL? I've been failing this exercise for the past 2 days, no hints are given, and my instructor still hasn't responded to my email.
I can't seem to use the YEAR and MONTH functions correctly
NVM I FIGURED IT OUT YAY
guys I need an idea
I gotta do a reaserch about 'unkown unkowns'
like I goota search abt someth that no one thought abt and then make a questionairre for my school students
so it has to be in the present and measurable
somone did abt the affect of sport on the academia
I wanna relate it computer science
any ideas?
Responsible AI?
You doing Movie Recommendation System right
err I think some of them can help but need to pay first
can i find someone who knows sql language
AI?
i would say c++ but it doesnt matter really. u can start with java or any u wanna focus on โค๏ธ
'let us C' Start with this book if you are complete beginner.
Dose anyone know JS?
Yes, but please lead with your questions
Im trying to make a avatar creator but im having trouble with updating the choice when picked
@honest nebula so how are yu implementkng that functionality
do you still need help for this?
Yeah
what is your intention with the last line of code?
I want it to appear on when a user clicks on the button
Hi, a friend of mine turned on some LEDS with arduino to like make them "blink" but she only used one resistor for 2 LEDS, can u do that? Because i always used as many resistors as LEDS cause i was convinced i it could ruin the LEDS otherwise, can anyone confirm if u can do it or not? They do turn on and blink as we wanted but we are gonna be graded on that (and other stuff) so i want to make sure its not a mistake
pls ping me if u can answer that
C
And the C programming language by Dennis Ritchie
The server you requested to does not support CORS
Each additional LED you light at the same time, all the LEDs will get dimmer. Youโll need higher and higher voltage to overcome the forward drop of each diode.
That's all that will happen
Anyone have php experience? trying to make my first functionable class
hello I just started learning java, does anyone know why the output of my code is 98 when i equate int a to 'b' even tho int b = 0? thanks in advance
on line 7 it should just be b no need for the ''
you would use '' if a is a string datatype and you are assigning it a value (string a = 'b')
So basically the LEDs wont get as much light but they wont be ruined, thats it? Also thank you!!
thanks a lot, but whats the underlying reason for 98 to be printed?
tbh i dont really know.
ok, thanks for ur help anyways
np. im pretty sure someone can answer if they know
its the ascii code of the character b see here https://www.cs.cmu.edu/~pattis/15-1XX/common/handouts/ascii.html
since you assigned your variable to the character (not string) b before and it was still an integer you print out the value of the character b, it is 98 since it converts the character to ascii code
Yeah they won't be ruined. The only thing that might take a little more stress is whatever you're using to power it. Though LED's are low voltage so it'll be fine!
98 is the character 'b' in ascii
Ascii character table - What is ascii - Complete tables including hex, octal, html, decimal conversions
Thank u, they are conected to arduino which is connected to a computer/laptop. But would u consider it a mistake not to connect with another resistor even tho it works like this? A bit afraid the teacher will consider it a mistake
I mean if its only 2 LED's it shouldn't lose any voltage. I would ask your teacher and see what they have to say about it
Alright thank you!
Yeah, in the real world its common to see quite a few LED's with a single resistor. Though high performance/high voltage LED's typically have their own resistors.
Okkk thank u so muchh
:)
Thanks alot
Hey, so basically for this project in arduino uno i have a sensor of humidity and temperature connected to the arduino which gives me the information, i also have a fan with me and i would like to program the fan to once the temperature reaches a determined number the fan starts working, for instance if the sensor says the temperature is 21ยบC the fan turns on until the temperature is below 21ยบC, however i honestly dnt know how to connect the fan to arduino, idk if i even have everything i need, nor do i know how exactly i could code it, can anyone please help? i will send the code i have so far and a photo of the fan, it has 12V, thank you! (Also yes i ve tried to search it up and i will continue to but im not finding what i need).
EDIT: came to the conclusion i dnt think i have everything i need to make it work, thx anyway
any student or grad DevOps or blockchain engineers?
question about c# System.IO StreamReader
i need to get the string from a txt file, when it's in Main() it works, but when i do it in a function it just returns null, the function is correct(it works if i replace it with the same string in the program rather than making it read from the file) so idk what is messing with it, or how to fix it
wohooo i made it work by not using ReadLine() but rather ReadAllText() and then splitting it into lines
Tech/cs/cis/mathematicians/mechatronics guys and gals can someone enlighten me which programming language used to build battlebots?
well yea but I gotta ask ppl about this to make research it has to be specific
Smth no one thought abt. ๐ค it could be any field or just education?
use c++
I think you have all you need, just connect the negative of the fan to ground in the arduino and the positive to a DIP that you want to use, make the code to put high Voltage level and your fan will start working
If you wanted to adjust the speed that's another story because you may need to simulate a PWM, I don't know what is it supposed to do...
Ah i think i tried that i tried a lot of stuff but the thing is dnt i need something to power the fan? Cause the fan is 12V and i dnt think it was receiving enough volts from arduino
I really just wanted it to move ahah
ohhh your fan is 12V
Yahh that is a issue right?
No sadly just 5v
mmm
I did see it move once but barely moved cause it dsnt have enough volts
But i dnt have anything to give it volts
yeah...
Well its ok i already send the report to the teacher and i wrote what i did but that i wasnt able to conclude this cause i didnt have all the materials necessary (all my material is borrowed and in college yah maybe i would have to buy it but in high school i think the teacher will understand). Thanks tho!
you could have tested it with another LED though
you imagine that another led ON is the fan ON and viceversa
I do have 2 LEDs but i didnt fully understand this
because you cannot make the fan work, because no 12V supply... you can pretend a LED is your fan
Ah to put the light on if the temperature reaches a determined number yah i did not think of that :'(
yeah
I am currently a bit busy but i will try that later and if i can i will update the report and resend it, thank u for the idea!
I used to do that back in uni when testing at home without the actuators, because those were at the lab
Yeah it was a good idea idk why i didnt think of that ahah thank you!
Next time, dont worry! My pleasure
@quiet vault รฉs portuguesa?
Talvez porquรช? Ahah
O cรณdigo que partilhaste tinha os comentรกrios em portuguรชs ๐
U are too?
Yes
Yeah, I also own a raspberry pi for personal projects
Cool, this is only for a physics project tho
Well, if you ever need help programming related or math, you can add me and we can talk in portuguese, I'm usually online
Sure, thx
Hey again i just did the idea u gave me and it worked just fine! Thx again!
Great!!
Hey I'm kind of new to programming and I wish to execute my function in the console but it doesn't seems to work
I executed the file before trying (obviously) but it still says that my function has not be defined yet
try to change the name of the return value of fusion()
return tabfusion not fusion
+1
Oh my bad I didnt even see that, thanks guys
No problem good luck with your program
anyone knows how to use microsoft access?
im trying to get this code to run but it keeps returning this error despite me checking the brackets several times, does anyone see any issue? this is being written in arduino in c
theres more code above that i can send if necessary but i think its a bracket problem isolated to this function
Youโre using else without if
You might want to put the two rotateRight() calls within the if scope and then else will work fine
I mean, you dropped an "}" before else, the error it's understandable enough
Look the code before the else if
The last else if
At the rotateRight you should put "}"
Hello
Do you know wether there is some good App/Website/program to track studying? Where you can log that you studied 2h of fluid dynamics and 1h of spanish etc and it then lets you visualize this data? I've been only able to find programs to plan study sessions, not to track them.
Hey, i think forest premium does that, it is payed but as far as i know its not too expensive, i dnt have it but if u search it up i think u will see it works for what u want
Or maybe try to see if any of these works better for u
honeslty, a simple excel sheet is the best tool for this
plus you can perform computation on the data data you log, for statistic purposes or whatever
And you can format the data however you want
It's a very very powerful tool once you understand how it works
Ew
hiii could someone pleasee tell me what is wrong between the line number 4 and 32 ,i'm really confuse,sorry for the italian```c++
#include <cstdlib>
#include <iostream>
using namespace std;
void MediaPonderata(float v[], float p[], int n){
int t=0,j=0;
float media,l=0,d=0;
for(int i=0;i<n;i++){
t=t+p[i];
}
for(int i=0;i<n;i++){
l=v[i]*p[j];
d=d+l;
j++;
}
media=l/t;
cout<<"la media ponderata e"<<media<<endl;
}
int main()
{
int n;
cout<<"inserire la quantita di voti"<<endl;
cin>>n;
float vt[n],vp[n];
cout<<"inserire i voti"<<endl;
for(int i=0;i<n;i++){
cin>>vt[i];
}
cout<<"inserire il peso dil voto in ORDINE"<<endl;
for(int i=0;i<n;i++){
cin>>vp[i];
}
MediaPonderata(vt[n],vp[n],n);
}
Can codechum still track activites even if the teacher is not in premium?
That's... The hole code
Also there is a few things wrong
Post the errors you are getting and pin me, tomorrow if no one helps you I'll reply, it's really late here currently
Copy the error name and Google it you will find many solutions for different problems and don't wait for others help focus in you work and try to figure out what's wrong there sorry I'm not into c language so yup good luck Mario hahaha <33
<@&717391911132069929>
i have a question with teams
what this shield in the upper left corner?
does it mean i can't use programs like obs to record my lesson?
i'm sorry,i didn't wanted to annoy you, i already searched on internet and changed the program before to sent it here,it's just that it still doesn't compile for a problem that i don't understand
@red hare
vt[n] gives you a float that is in position n in vt, the function is asking for a pointer to the start of a float array, just delete the [n] part
same for vp
it now gives me this, i already tried taking off the n,before but this happened,i serached on internet but i didn't get it.Sorry i'm not really good doing this
remove the []'s too when you pass the array to the function
just the name of the array
or if you insist on using []'s, do &vt[0]
thank you sooo much
you were really helpful
thanks for being patient with me, i really apreciate it
โค๏ธ
Prob just means data between you and members travels end-to-end encrypted
any time
It's means the data of the meeting is encrypted following Teams standard for data encryption.
By requiring all servers to use certificates and by using OAUTH, Transport Layer Security (TLS), and Secure Real-Time Transport Protocol (SRTP), all Teams data is protected on the network.
You can still use OBS to record your session, it has nothing to do with what they are saying
They are only referring to how the data is passed around
OBS looks at your computer video memory, not network traffic
I am a beginner at programming and want to start competitive. Therefore I am looking to start with C++ as it is regarded best for competitive. Now I might even get into embedded systems programming which requires c. Now I need to how much time is needed to learn C if I already know C++? And is the switch difficult?
anyone know how to wrap code with github markdown?
Hi! In C++
I'm trying to add words one by one to a string using cin. In a way that if I write a word that's already in the string, my program quits. But I'm completely lost and don't know how to do that. Could anyone help me?
Hey is this helpful https://stackoverflow.com/questions/2340281/check-if-a-string-contains-a-string-in-c ?
Does anybody know what :@: means in Haskell?
I saw it in the defn. of a datatype:
| Termโ :@: Termโ
nvm, apparently it means application in the paper I'm reading
Does anybody know if it is possible to have two datatypes reference each other in its definition in Agda? Apparently its possible in Haskell which Agda is based on. Something like:
type A :
_+_ : A -> B -> A
zero : A
type B :
_-_ : B -> A -> B
O : B
The type is nonsensical but gets the point across
Lol, does anybody know if there is an equivalent to ref int in Agda or a number that stays in memory as the program is running. I would think not because Agda isn't a programming language but a proof checker, but I figured I'd ask in case somebody could confirm
If the message above contains a link to free nitro, it is most likely a phishing link. Please DON'T click on it to protect your privacy. You can notify the peeps by tagging them ( @peeps ) and they will take care of it as soon as they can.
what do you need?/what is your question? I might be able to help
I think so!! Thank you!
Reflective programming? ๐
anyone has done google analytic course before??
could someone explain to me the shannon fano algorithm? I never get the right number of questions for each letter
`function numBox() {
var dropdown = document.getElementById("boxSize").elements["number"];
console.log ('working')
for (var i = 1; i <= dropdown.value; i++){
var newBox = document.createElement('div')
var colour = document.getElementById('boxSize').elements['colour'].value
var colGen = colorGen(colour)
newBox.setAttribute('id', 'div')
document.body.appendChild(newBox)
console.log(colGen[0])
var x = colGen[0]
var y = colGen[1]
var z = colGen[2]
var generatedCol = 'rbg(' + x + ',' + y + ',' + z + ')'
console.log (generatedCol)
newBox.style.backgroundColor = generatedCol
}
}`
can someone tell me whats wrong with this code
im trying to get it to generate random colours and it all works in the console
but i cant get it to actually output the colours
in detail or just what it's for?
nvm solved it
Can someone help me with this? ```python
class Matrix:
def init(self, matrix):
self.matrix = matrix
self.rows = len(matrix)
self.columns = len(matrix[0])
def __str__(self):
pass
I tried
return "\n".join(" ".join(map(str, row)) for row in self.matrix)
But the instruction says to display two characters per number (and a space in between)
Matrix is a list of lists btw, so for example [[2, 4, 6],[8, 10, 12],[14,16,18]]
Has to be printed like this
I was asking for a general method but I actually understand it now! Thank you โค๏ธ
can anyone suggest me a book for c++ beginner to advanced(with good STL explanation) main target:competitive
idk if this is the right channel to ask this but:
How can I iterate backwards in an array with a for() thing?
(C++ related)
like go backwards in an array
cause that is something that will be in my exam and I honestly have no clue.
yeah I was thinkign about that
hmm I still don't knwo tried that but it is not working
:(
what are you trying to do
make an array,
and go backwards in it with a for thing
and then cout it
int[] arr = new int[]{1,2,3,4,5,6,7};
for(int i=arr.length-1;i>=0;i--){
cout<< arr[i] << \n;
}
im pretty sure this is it
do ` three times follow by cpp then paste ur code and end with the three ticks
or pastebin
well it says that it can't get the length of the array
do u have elements in the array?
i have it like this int arr[]{1,2,3,4,5,6,7};
and then in the for thing:
cout << " text " << arr[i] << endl;
} ```
still doesn't work
;_;
compiler error says: request for member 'length' in 'x', which is of non class type 'int [7]'
pain
yeah i googled u have to use sizeof
i was doing java syntax
hmm lemme build a working array going upwards first
i'll see what I can change then
try watching this
This video will teach you some seven ways to get the length of arrays in C++. It uses seven different examples to explain the process.
00:00:07 - Introduction
00:02:34 - Example one: Using the sizeof() function to calculate array length
00:04:55 - Example two: Using a pointer to find the length of array
00:06:49 - Example three: Using the STL (a...
yeah np
Hello guyss i have an homework about code writing can someone help me with it ๐ฅฒ
Can someone help me with this code?
I dont know why is_category_valid('bus', L) and is_category_valid('railway', L)return False
when i try is_category_valid('salary', L) is_category_valid('bonus', L), it return True
L=['expense', ['food', ['meal', 'snack', 'drink'], 'transportation', ['bus', 'railway']], 'income', ['salary', 'bonus']]
def is_category_valid(category, categories):
if category not in categories:
for v in categories:
if type(v)==list:
p=is_category_valid(category, v)
if p == True:
return True
if p != False:
return False
else:
return True
print(is_category_valid('bus', L))```
i found the answer to that one:
size_t size_arr = sizeof(arr) / sizeof(int);
for (size_t i = size_arr - 1; i > 0; i--) {
cout << "Array: " << arr[i] << '\n';
}
only problem left is: how do I do that when i = 0 and it should count from 7 downwards?
oh well don't care and fixed anotehr smol issue with that code lol
if p== true and if p != False is same thing
If the message above contains a link to free nitro, it is most likely a phishing link. Please DON'T click on it to protect your privacy. You can notify the peeps by tagging them ( @peeps ) and they will take care of it as soon as they can. Please don't ping them if someone else already did in the chat thank you.
thank you
<@&717391911132069929>
does someone understand how to use CAD?
Deleted the message, user already banned
thanks๐
wait user banned already?
yeah i tlooks like the message didnt delete 
guys can someone teach me how to install a sql map
do you guys know how I can make my program stop in c++ ?
I use return(0) but it's not working T.T
is there someone who wants to help me with a program? itโs written in html/javascript/python/sql
if its a basic program you would just control, otherwise try these https://docs.microsoft.com/en-us/cpp/cpp/program-termination?view=msvc-170
return 0 is for int functions and the main function
Iโm going to try thanks !
any one wanna learn flutter
Amigos. anyone in cybersecurity field? pls
guys my instagram acc have hacked and ig current acc mail is different different from my original mail and ฤฑdk what should ฤฑ do. i tried to get help but i couldn't. If you guys know this things please help me
hey guys, i hope i'm not bothering anyone but i'm thinking of taking a course that include a lot of game and web design
does anyone have advice on how to not fail? i'm usually afraid of coding and the like so if anyone had a similar experience to mine i could definitely use some advice
idk maybe take notes
who reacted with the laugh emoji
Taking notes is not the most effective way to learn coding. The best way to learn coding is to keep practicing and build up what you already know.
I was in your shoes once, my advice is donโt procrastinate on your course, if youโre a beginner, itโs not an option. You would find yourself coding for 5 hours solving one easy question before you know it so always do your homework the day before. Donโt be afraid to look up answers, the internet is your guide! Copying code is not bad, however no progress comes at the cost of copying, so try to understand the code as youโre writing it, google what you donโt know and donโt copy paste everything down. I was afraid to code because I was comparing myself to other students but DONโT. We all are on a different path. What matters here is our own progress. Work on yourself.
yeah i made that mistake taking notes when i should have been just trying to code something even if it took me months to build my own wealth of knowledge
Same, all my classes are online and my c++ prof gave us pdfs each week. I took down notes but didnโt really write many codes either. The only thing I learned from that class are the terms/ function names and data structures 
can someone explain to me why the second line is necessary
why would you need to assign everything to assign it to another variable
also, why do you need to put the math method in the array
your PFP is from moon remix
that PS1 game
yes lol
it's a weird game
does anyone know how to check if a string is in uppercase in c++ ?
try using this
im not an expert at c++ so you'll have to forgive me if i give you bad advice, im still learning
oh and this too https://en.cppreference.com/w/cpp/algorithm/all_any_none_of
thank you i will check it out!!
THANKKK YOUUU SOOO MUCHH
i really appreciate thisss
thankk youu
oh wow,thank you for telling me this because i love taking notes, but this was so helpful
wished i read this before the end of the semester 
Hey
Please, create CRUD program in OOP (choose any comfortable for you programming language)
The topic of database: "types, markings and designations of paints and varnishes"
It should be at least 3 tables in database
Hope you can help
Thanks
Can someone help me with a python code real quick
What language are you going to use
i think php
Are you required to use a database though like MySQL or something?
yes
one moment
I also wrote some code
to select all from every table
but idk what to do next
(such as insert data, edit row, delete row)
Here i connected database:
Here I created new class, which extends connection class; and function that selects all from table "type":
Then I created view class (which i can call in future app):
can you do insert/edit/delete functions please?
just for one table
lfm_type
Do you know SQL?
it will just be like function deleteType(id){ $sql = "DELETE FROM lfm_type WHERE type_id = " + id + ";"; }
for delete
it is all very similar
I don't write PHP so it may be wrong for function definition
can someone explain to me where I put the dots I mean how it works and what's the reason for it?
True and false are Boolean statements
Itโa not going to return anything if you didnโt declare a statement.
first_run = True means that we assign the boolean value True to a variable that we name first_run
The same goes for first_run = False -> we update the value of our previously-created variable first_run so that it now stores the boolean value False
if first_run: is just a Python syntax shortcut for if first_run == True:
They do exactly the same thing, but the first feels more natural because you could read it as "If it is the first run, do ..." (because that's what the variable first_run represents)
whats your problem?
