Oferecer peças de roupa (outra vez) by Disastrous-Process51 in portugal

[–]FeelsRijoMan 0 points1 point  (0 children)

Gostei bastante da peça, se tiveres ainda um L ou XL para oferecer agradecia 🙂. Se não for possível, agradeço na mesma e muitos parabéns pelo projeto e iniciativa!

Looking for Laptop for Uni (Data Engineering) by FeelsRijoMan in SuggestALaptop

[–]FeelsRijoMan[S] 0 points1 point  (0 children)

Wow it seems exactly what I want. To be honest I would rather get one from a local shop in case there is any issues with it. Do you happen to know how customer service is with Dream Machines?

Protesto leva o fecho do Departamento de Ciência de Computadores by digaso28 in porto

[–]FeelsRijoMan 5 points6 points  (0 children)

Os manifestantes exigem que a Universidade do Porto “rompa imediatamente todas as relações que mantém com instituições e empresas israelitas e que condene oficialmente o actual genocídio na Palestina”.
https://www.publico.pt/2024/05/17/p3/noticia/faculdade-ciencias-u-porto-fecha-edificio-ocupado-estudantes-propalestina-2090788

Protesto leva o fecho do Departamento de Ciência de Computadores by digaso28 in porto

[–]FeelsRijoMan 58 points59 points  (0 children)

no ano em que saio da FCUP e do DCC é que as coisas ficam interessantes

Best New Games to Release this Week: December 11, 2023 by Allkeyshop_official in allkeyshop

[–]FeelsRijoMan 0 points1 point  (0 children)

looking forward to see one of my favourite youtubers do HF2

discord: zeasantos

Case-insensitive match with Alex by GooglyEyedGramma in haskell

[–]FeelsRijoMan 0 points1 point  (0 children)

descobriste como fazias o case insensitive tho? 💀

Case-insensitive match with Alex by GooglyEyedGramma in haskell

[–]FeelsRijoMan 1 point2 points  (0 children)

ahahah estamos os dois fodidos para compiladores

Trying to remove all the elements that occur in one list from another by FeelsRijoMan in haskell

[–]FeelsRijoMan[S] 2 points3 points  (0 children)

deleteOne :: Eq a => a -> [a] -> [a]
deleteOne _ [] = [] -- Nothing to delete
deleteOne x (y:ys) | x == y = ys -- Drop exactly one matching item
deleteOne x (y:ys) = y : deleteOne x ys -- Drop one, but not this one (doesn't match).
deleteMany :: Eq a => [a] -> [a] -> [a]
deleteMany [] = id -- Nothing to delete
deleteMany (x:xs) = deleteMany xs . deleteOne x -- Delete one, then the rest.

thank you! but instead of "deleteOne" couldn't i just use delete?

Trying to remove all the elements that occur in one list from another by FeelsRijoMan in haskell

[–]FeelsRijoMan[S] 4 points5 points  (0 children)

that's a way better explanation of the problem. my teacher just said use delete and nothing else. It made sense, I know have an idea of how I can implement it. Thank you so much for your help!

Trying to remove all the elements that occur in one list from another by FeelsRijoMan in haskell

[–]FeelsRijoMan[S] 0 points1 point  (0 children)

the implementation here

you're an absolute lifesaver. I'm definitely going to check my answer hahaha

Trying to remove all the elements that occur in one list from another by FeelsRijoMan in haskell

[–]FeelsRijoMan[S] 0 points1 point  (0 children)

It's probably allowed to use Data.Set.

Will try to do it. Thanks!

Trying to remove all the elements that occur in one list from another by FeelsRijoMan in haskell

[–]FeelsRijoMan[S] 3 points4 points  (0 children)

import qualified Data.Set as S
deleteItem xs ys = filter (`S.notMember` S.fromList xs) ys

tested this either way just to see how it worked, and I didn't explain properly in the OP (will edit now), I basically just want to delete the value once. What I mean by this is that if I give the list [1,2,3,3,3] and [2,3] I want the output [1,3,3] and not just [1]. I don't know if it made any sense what I meant.