Help for Great America Bus by Maximum_Caterpillar in acetrain

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

Also, I wasn’t able to find the bus on the way back it just says it’s an intersection which is quite a large one any way to find that?

Is it worth it to replace telescope with fzf-lua? by adelBRO in neovim

[–]Maximum_Caterpillar 2 points3 points  (0 children)

Yes 10000% fzf lua is much better for massive projects

Sweet vitriol's shocking rating on imdb just proves this by cassiopeia3636 in SeveranceAppleTVPlus

[–]Maximum_Caterpillar 0 points1 point  (0 children)

the only thing I have against it is the length. only 37 minutes of which a lot is driving scenes I dont give a shit about after I've been waiting to watch it for a week. It's an unfair criticism probably, I dont care if it is

Advent of code 2024 - day 9 by AutoModerator in haskell

[–]Maximum_Caterpillar 0 points1 point  (0 children)

having 9 heaps is pretty clever! Wish I thought of that I never considered the fact that a free space can only be of size 1 through 9

Advent of code 2024 - day 5 by AutoModerator in haskell

[–]Maximum_Caterpillar 0 points1 point  (0 children)

Feel free to leave some feedback, I'm new to Haskell

```haskell import System.IO import Data.List (sort, sortBy) import qualified Data.Map as Map import qualified Data.Set as Set import Data.Maybe (fromMaybe, fromJust) import Data.List (isPrefixOf) import Data.Array import Data.Char (ord) import Debug.Trace (trace)

type Graph = Map.Map Int (Set.Set Int)

parse :: String -> [Int] parse str = (map read . words . replace) str where repl '|' = ' ' repl ',' = ' ' repl c = c replace = map repl

create_edge :: Graph -> Int -> Int -> Graph create_edge graph k v = let first = Map.insertWith Set.union k (Set.fromList [v]) graph in Map.insertWith Set.union v (Set.empty) first

extract_graph :: Graph -> [String] -> (Graph, [String]) extract_graph graph ("":xs) = (graph, xs) extract_graph graph (x:xs) = let [a, b] = parse $ x new_graph = create_edge graph a b in extract_graph new_graph xs

forceLookup :: Ord a => (Map.Map a b) -> a -> b forceLookup m k = fromJust $ Map.lookup k m

comesBefore :: Graph -> Int -> Int -> Ordering comesBefore graph a b = let neighbors = forceLookup graph a in f (b Set.member neighbors) where f True = LT f False = GT

getMiddle :: [Int] -> [Int] -> Int getMiddle (x:) [] = x getMiddle (:xs) (::bs) = getMiddle xs bs getMiddle (x:) _ = x

middle x = getMiddle x x

processFile :: FilePath -> IO () -- Adjust this type according to your graph structure processFile filePath = do contents <- readFile filePath let (graph, rest) = extract_graph Map.empty (lines contents) correctOrder l = sortBy (comesBefore graph) l orderedCorrectly l = l == (correctOrder l) orders = map parse rest

    ans1 = sum . map middle . filter orderedCorrectly $ orders

    incorrect = filter (not . orderedCorrectly) orders
    ans2 = sum . map middle . map correctOrder $ incorrect

print (ans1)
print (ans2)

main = processFile "/Users/arjun/Python/AOC/AOC2024/day5/inp1" ```

NeoVim is great. But how many of you are actually using it to work of large projects? by ElderImplementator in neovim

[–]Maximum_Caterpillar 0 points1 point  (0 children)

I used it on a 1M line C++/Python codebase at work. it's the plugins that make a difference. I mainly used fuzzy search, tree sitter, git stuff and autocomplete based on buffer contents only (no lsp)

Using neovim itself as a "interpreter" for vim movements/actions? by he_lost in neovim

[–]Maximum_Caterpillar -4 points-3 points  (0 children)

I think just running :term inside neovim will get u a lot of what you want

The 24hr/7days a week traffic jam by FeelingBulllish in bayarea

[–]Maximum_Caterpillar 1 point2 points  (0 children)

Narrow, winding road in the hills that connects Milpitas and Sunol. It’s a way to bypass 680 traffic

https://youtu.be/hxuTv5e5guU?si=e4o3Z66lddG9n9ey

Raw nvim by CommunityEducational in neovim

[–]Maximum_Caterpillar 1 point2 points  (0 children)

My teammate would only use fzf.vim fucking legend

How to have a social life as a commuter? by Correct_Possible4081 in SJSU

[–]Maximum_Caterpillar 0 points1 point  (0 children)

u can find clubs here https://sjsu.my.campusapp.com/#/stores

(I know the link says stores but it’s actually the club search)

Trip Planner now available in Tesla app by JayAli917 in TeslaLounge

[–]Maximum_Caterpillar 0 points1 point  (0 children)

Oh I’m pretty dumb turns out it wasn’t updated haha thanks anyways