Quick block post about code quality. https://lnkd.in/g74FWEbT #spreadsheetsurgeons #spreadsheets #excel #adelaide #codequality
Spreadsheet Surgeons’ Post
More Relevant Posts
-
If you want a boost in productivity. Then try custom shortcuts in VS Code. If you're spending a lot of time coding in VS Code, setting up your own shortcuts can make a huge difference! I’m talking about those little actions like opening the terminal, toggling comments, or running code, those that we do so often so they almost feel automatic. Want to try it? Head to File > Preferences > Keyboard Shortcuts and set up commands you use most. Every second saved counts when you’re deep in a project! Setting shortcuts for these actions has genuinely shaved off precious seconds every time which adds up to a faster workflow overall.
To view or add a comment, sign in
-
Rules to Write Better Code 1. Start Small and Build Gradually Write simple programs first and test your code frequently. Break problems into smaller, manageable tasks. 2. Write Descriptive Variable and Function Names Use names that explain the purpose of the variable or function. Avoid vague names like x or temp. 3. Comment Your Code Add comments to explain the why, not the how, of your code. This helps others (and your future self) understand it. 4. Follow Consistent Formatting Indent code properly, use consistent spacing, and avoid overly long lines. Tools like black or flake8 can help. 5. Don’t Repeat Yourself (DRY Principle) Avoid duplicating code; use functions to reuse logic. Follow for more!
To view or add a comment, sign in
-
Increase Code Efficiency by using 𝗗𝗶𝗰𝘁𝗶𝗼𝗻𝗮𝗿𝘆 𝗖𝗼𝗺𝗽𝗿𝗲𝗵𝗲𝗻𝘀𝗶𝗼𝗻𝘀! For loops build dictionaries but can be verbose and inefficient. They require multiple lines for iteration and conditionals, cluttering the code. 𝗗𝗶𝗰𝘁𝗶𝗼𝗻𝗮𝗿𝘆 𝗰𝗼𝗺𝗽𝗿𝗲𝗵𝗲𝗻𝘀𝗶𝗼𝗻𝘀 allow dictionary creation in a single line. They enhance readability and efficiency, clarifying intent and reducing errors. However, avoid them when logic is complex or involves multiple steps.
To view or add a comment, sign in
-
A treatise on improving the code base performance #Performance, #SoftwarePerformance #FirmwarePerformance, #CodePerformance Of Example considerations: Coding Different logic constructs have different performance timings · Have you timed different constructs that will have the same outcomes? · Are you using the constructs that are fastest? · How do code reviewers/approvers know why you selected a construct (details)? The Switch or if-then-else constructs simulating a switch: · Case order may have critical performance outcomes. · Did you analyze the case statements with a performance filter? Balancing performance and complexity · Is there a code tree that is part of a high-speed loop? · What happens if you reduce the number of modules by combining some or all code tree modules? o Performance change o Complexity change · Since you are combining modules, complexity will rise, and performance will improve. Check List · What code segments are performance critical? · Have you timed the performance-critical code? · Have you used the logic constructs resulting in time improvements? · Did you rework a code tree? If so, what are the changes to performance and complexity? · Have you flagged timing critical areas of the code? · Have you tested the changes under load? · Do you have any mechanism for balancing the load? Results 1) Time-critical areas of the code are flagged. 2) Changes to improve performance are documented. 3) The performance improvements are recorded. 4) The reasons for tree decompositions are documented, including changes to performance and complexity 5) The case order changes are documented. Please feel free to send any questions as a comment.
To view or add a comment, sign in
-
Fed up with failed attempts at predicting future needs? Can't stand those over-engineered solutions anymore? 🚀 Simplify your codebase with YAGNI and KISS! 🚀 Discover the power of these architectural principles and keep your code lean, clean, and maintainable. Understanding these principles will eliminate overengineering and keep your codebase lean, improving maintainability and facilitating onboarding new team members and your life as a codebase maintainer. Murphy's Law states that "anything that can go wrong will go wrong". It emphasizes the inevitability of errors and the likelihood of adverse outcomes in complex systems or situations, highlighting the importance of simplicity in design to mitigate potential problems. 💡 Takeaway: YAGNI and KISS principles help you avoid unnecessary complexity, making your software easier to manage and evolve. 🗨️ Comment below with your experiences with bloated or overengineered codebase, or tell us how you've simplified your code using these principles! #ASPNETCore #SoftwareArchitecture #dotnet #csharp #DesignAndArchitecture #CodeDesign
To view or add a comment, sign in
-
Codeforces Round 963 : Editorial : A-C A - maximum correct answer for one type of option will be n, hence just add the minimum of (n, frequency of each option) for each option and output it. i.e answer += min(n,count[option]) for all options (A,B,C,D) B - pick the highest odd number, start adding even numbers to it from smallest to highest, if at any point the current odd number you are getting after several addition of some prefix of even numbers is smaller than the next even number then you are bound to spend 1 extra step else you just have to spend number of moves equal to the count of even numbers. C - if the answer is possible, then it would be some number in the range => (Highest_array_value, Highest_array_value+ K -1) Now for each element find the closest range near Highest_array_value in which it is On. Use Difference-Array to update the range you got. Now after this just check the smallest number for which the count you are getting is N.
To view or add a comment, sign in
-
Functions can make your code less messy. In earlier days I used to write same code multiple times, until I learned about the functions. Function is a block of code that takes input and gives some output. It is not necessary for function to give output. The same code I was writing multiple times can be converted to the code of few lines using functions. Functions can make code easy to maintain. Suppose, I am writing same code multiple times. After some days I came to know that it has a bug. Now I need to make changes in every repeated block of same code. But if I have a function, I can make changes in function only and changes will reflect in the whole code. And code is ready to go! What are your thoughts on functions? Feel free to share in comments. #softwareengineering
To view or add a comment, sign in
-
💡 Ready to take your development to the next level? Creating custom snippets in VS Code can help you: - Work quicker - Simplify your routine - Stay focused Discover the steps in our full article! 🔗 https://lnkd.in/eZYCQKEU
Creating Custom VS Code Snippets for Faster Development | by Niall Maher | Codú
codu.co
To view or add a comment, sign in
-
Increase your productivity in VSCode! Basic Navigation and Editing: 🎯 Ctrl + P: Open a file by name. 🖱️ Ctrl + Shift + N: Create a new window. 📝 Ctrl + Shift + P: Open the command palette. ⏩ Ctrl + Tab: Switch between tabs. ⏮ Ctrl + Shift + Tab: Switch between tabs in reverse order. 📚 Ctrl + \: Show/hide the side panel. 🏢 Ctrl + B: Show/hide the activity bar. 🔎 Ctrl + F: Find. 🔍 Ctrl + H: Replace. 🔁 Ctrl + D: Select the next occurrence of the current selection. ⬅️ Ctrl + U: Undo the last selection. 📌 Ctrl + L: Select the current line. Editor Navigation: 🗺️ Ctrl + G: Go to a specific line. 🗺️ Ctrl + P + Line Number + :: Go to a specific line. ↩️ Ctrl + -: Go back to the last cursor position. ↪️ Ctrl + Shift + -: Go forward to the next cursor position. ⬅️ Alt + ←/→: Go back/forward to the last cursor position. ⬅️ Ctrl + Shift + ←/→: Select word by word. Text Manipulation: ✂️ Ctrl + X: Cut line or selection. 📋 Ctrl + C: Copy line or selection. 📥 Ctrl + V: Paste line or selection. ❌ Ctrl + Shift + K: Delete line. ➕ Ctrl + Enter: Insert line below. ➕ Ctrl + Shift + Enter: Insert line above. 🔃 Shift + Alt + ↓/↑: Move line up or down. 🔀 Alt + ↓/↑: Move line or code block up or down. 🔑 Ctrl + Shift + ]: Go to the matching opening or closing brace. Code Refactoring: 🔍 F12: Go to definition. 💡 Ctrl + F12: Go to definition quickly. 🔎 Shift + F12: Find all references. 🔍 Ctrl + Shift + F: Search in files. 🔎 Ctrl + Shift + H: Replace in files.
To view or add a comment, sign in
-
Optimize your code for efficiency and productivity: Planning and Design 1. Think before you code 1. Spend time understanding the problem you're solving 2. Break it down into smaller tasks 3. Plan the overall structure of your code by looking at it from an higher perspective. Look at all the moving parts. 2. Algorithm choice matters, but not that often 1. At times the algorithm you use in a scenario does not matter because the input size can never be large enough to make a difference. So first thing is to know if you need to optimize at all. 2. Select algorithms with good time and space complexity for your specific task. 3. Consider factors like the size of your data and the desired speed of execution. 3. Modularize your code 1. Break down your code into smaller, well-defined functions or classes that perform specific tasks. 2. This improves readability, maintainability, and reusability.
To view or add a comment, sign in
66 followers