[Substantially edited after discussion – see comments.]
The post contains a general argument pattern, and a particular argument which tries to instantiate that pattern. Neither is formulated very carefully, so my reconstructions may not be what OP had in mind. Starting with the argument pattern, (p) is a quote from the post and (P) my reconstruction.
(p) If “something is more or less hopeless, […] there is no point trying to expand any effort on it.”
(P) If there is no hope that X will be achieved, then trying to achieve X is pointless.
Note that (p) talks about ‘more or less’ hopeless situations. While it matters just how hopeless the situation is, let’s first focus on situations that are completely hopeless. In turn, if ‘there is no hope that X can be achieved’ is read as ‘it is impossible to achieve X’, then (P) can be unpacked as follows:
(P.1) It is impossible to achieve X.
(P.2) X will not be achieved.
(P.3) There is no point in trying to achieve X.
Barring subtle questions about temporal modal logic, (P.2) follows from (P.1). Getting (P.3) from (P.2) is more difficult formally as we don’t have a formal semantics for the operator ‘it is pointless to try _’. Still if you know you won’t do x, it does seem right to infer that it is pointless to try. In fact, if you already know you won’t/can’t do x, many hold that you can’t even intend to do x. (That's one interpretation of Kavka’s toxin puzzle, I think.) Thus, if (P) is tantamount to (P.1) – (P.3), then (P) is non-fallacious, and in that sense 'valid'.
Turning to situations that are less than completely hopeless, let’s replace (P.1) with (P.1*).
(P.1*) It is unlikely that that X will be achieved.
While (P.2) no longer follows, there’s a sense in which (P.3) is supported by (P.1*): if X is unlikely enough, then the expected value of attempting to achieve X may be a loss. E.g., unless the jackpot is very large, you’d expect that buying a lottery ticket will lead to a loss of money. That may not make the purchase entirely pointless; but everything else being equal, the rational choice is not to buy the ticket.
Let’s now turn to the particular argument, with (a) being a quote and (A.1) to (A.3) being my reconstruction.
(a) “there are already more guns than people in the US, therefore it is a lost cause, there is no point trying to improve the situation with guns in the US”
(A.1) There are more guns than people.
(A.2) Thus, there is no hope that gun safety can be achieved.
(A.3) Thus, there is no point in trying to improve gun safety.
Note that (A.2) does not follow from (A.1): while (A.2) may be some kind of ‘empirical consequence’ of (A.1), we can easily imagine a situation in which (A.1) is true but (A.2) false. (I’ll leave that to the reader.) One could try replacing (A.1) with e.g. ‘There are too many guns for us to control’, but I don’t think that will help: it’s still not clear that (A.2) follows. Worse, (A.1) begs the question, and may also contain a false disambiguation: people might agree to ‘There are too many guns’, but then ‘too many’ is (illicitly) interpreted as ‘too many to control’.
Finally, there’s the step from (A.2) to (A.3). This is supposed to be an instance of (P), but I don’t think it is: while (A.2) seems to talk about achieving complete gun safety, (A.3) concerns attempts to improve gun safety. (Btw., I’m leaving open what ‘gun safety’ actually amounts to.) In other words, rather than being an instance of (P), the step from (A.2) to (A.3) is similar to the fallacy of division, illustrated by (i) and (ii):
(i) We can’t save all the drowning castaways.
(ii) Thus, we can’t (and shouldn’t try to) save any of the drowning castaways.
We could try to replace (A.2) with (A.2*), or (A.3) with (A.3*). While either would yield an instance of (P), (A.2*) is much less convincing than (A.2), and (A.3*) leaves open that gun safety can be improved - albeit not to perfection.
(A.2*) There is no hope that gun safety can be improved.
(A.3*) There is no point in trying to achieve (complete) gun safety.
Conclusion. While the OP’s argument pattern is non-fallacious (under one reconstruction), the particular argument isn’t an instance of this pattern. It can be turned into such a pattern, but it is then either not convincing or not interesting.