pull down to refresh
@rblb
46,776 sats stacked
stacking since: #352021longest cowboy streak: 3 verified stacker.news contributornpub1klt4m...pcysd4kr0priccardobl
0 sats \ 1 reply \ @rblb 14 Feb \ on: Chornobyl Nuclear Power Plant sarcophagus hit by Russian drone news
I bet they are the same 'russians' who blew up the european gas pipeline
By their own admission, they have always been a Bitcoin company; we just didn't know. https://x.com/ProtonWallet/status/1866866021413556294
Damn, people really go out of their way to reinvent shitty oop.
class Discount {
constructor(rate){
this.rate=rate;
}
apply (v) {
return v * (1 - this.rate);
}
}
const regularDiscount = new Discount(0.1);
const premiumDiscount = new Discount(0.2);
console.log(regularDiscount.apply(100));
console.log(premiumDiscount.apply(100));
console.log(regularDiscount.apply(200));
I did the math and it is pretty much what we are supposed to pay in italy, except that we have ways to legally trick it.
Eg. if you use the right combination of taxcode and profession, the state will require you to not pay taxes on a % of your income due to it being considered expenses, while your actual expenses are much lower, giving you a defacto taxcut. This is 100% legal, the catch is that you need to have some favorable conditions to benefit from it and close but not more than 85k yr income (the closer you get to the limit the more favorable it is).
If you don't have a way to do this in spain, things look very bad.
Please Darth stop ruining the magic. Let's just pretend things just work until they don't 🗿
Also, realistically you would need a ton of spam to trigger rate limit with nwc.
As a dev who rejects modernity and embrace tradition, this is my string based approach
public boolean isPalindrome(int x) {
String s = "" + x;
int l = s.length();
for(int i = 0;i < l;i++){
int j = l-1-i;
if (s.charAt(i)!=s.charAt(j)) return false;
}
return true;
}
and integer based approach
private int reverse(int n){
int r = 0;
while(n != 0) {
int d = n % 10;
r = r * 10 + d;
n = n / 10;
}
return r;
}
public boolean isPalindrome(int x) {
if(x<0)return false;
return reverse(x)==x;
}
To add on this, i've tried also cursor (thanks to @k00b), that is nice but I’ve noticed it is somewhat more opinionated about code compared to copilot.
In my experience, copilot feels like it is following you and just completing the code, while cursor feels like it is trying to anticipate what you will want to do several steps ahead. I prefer copilot, but I think it is a matter of personal taste and coding style.
I've been trying Github copilot reviews, that is another beta service, but it doesn't work very well , at least with our code base, but it can catch some oversights, sometimes.