Author: Vitosh

VBA – Sum array with recursion

This is what Wikipedia says about Recursion: Recursion occurs when a thing is defined in terms of itself or of its type. Recursion is used in a variety of disciplines ranging from linguistics to logic. The most common application of recursion is in mathematics and

Tagged with: ,

VBA – How to refer a function ByVal, when the parameter is explicitly ByRef

Ok, you have read the title correctly – there is a way to refer a parameter ByValue, even though the parameter contains explicitly the word ByRef in it. Let’s start with the functions. Imagine a function, getting an array as parameter

Tagged with: , , ,

VBA – Find function in Excel does not return the first value by default

The Range.Find() function in VBA-Excel is quite a tricky one. In general, you may think it is straight forward, because it usually returns what you are looking for, until the moment when it simply surprises you. This is the MSDN description

Tagged with: , , ,

VBA – Type Declaration Suffixes

If you are coming from the .Net world, then you are used to declare variables like this:

In this case, both foo and bar are of type Long. Then, someone tells you that you want to switch for a

Tagged with: , , ,

VBA – Attributes. The high-end in VBA.

You have probably noticed, that whenever you export a class module from the Visual Basic Editor, you get some strange lines in the exported file, above the Option Explicit. This is something, that you have not written, but it is

Tagged with: , , ,

C# – CodeForces – Chtholly’s request

Solving problems at CodeForces is a kind of hobby. Lately, in round 449, division 2, there was a problem which has met my interest. It has to do with palindromes and really big numbers. The problem is easy to calculate,

Tagged with: ,

VBA – RegEx in Excel – Part 2

After the first part about RegEx in Excel lately I had to do something else with RegEx. The task was quite simple, pretty much called “stripping a string”. The idea is that you have a string and you should remove all

Tagged with: , , , ,

VBA – Join a Collection (Collection to Array)

Working with VBA is sometimes trivial  – you need to rewrite and reinvent the wheel every now and then 🙂 I mean, defining your own sorting method, your own test driven developement framework, etc. But, this is the funny &

Tagged with: , ,

Book Review – Clean C++

Time has passed since my last review in VitoshAcademy and thus I have requested a new great book from Apress.com for a review. Although I am not a C++ developer (and I have never been paid to develop on anything

Tagged with: , , ,

VBScript Simple Program – Problem in CodeForces

In order to learn a language, the best way is to practise it! Thus, I have decided to challange myself to solve a task on CodeForces with VBScript.  As far as VBScript is not one of the official CodeForces languages

Tagged with: , , ,

VBA Online Resources

cpearson.com rondebruin.nl msdn.microsoft.com/en-us/vba/vba-language-reference www.guru99.com/vba-tutorial.html Riptutorial.com (Ex documentation from StackOverflow) Excel Microsoft MVPs  The blogs above are one of the top Excel/VBA blogs that I know. If you are interested in exchanging VBA links, please feel free to contact me at

Tagged with:

C# – CodeForces – Table Tennis

The Table Tennis problem in CodeForces was looking actually easier than the Borya’s Diagnosis. However, I have decided to publish it, because I have managed to “lie or cheat” the CodeForces system with it in a cool way. Currently, I

C# – CodeForces – Borya’s Diagnosis

Every time, wherever I decide to take a look at CodeForces and to code & publish some of the easy problems, I am thinking that this is probably the last one, because it is too easy. However, I always find

Tagged with: , ,

VBA Excel – How to convert range to array easily

Converting a range to array makes a lot of sense in VBA, when some operations should be performed with data in a given range. The time saving is quite noticeable and it is a bit easier to access and modify

Tagged with: , , , ,

VBA – RegEx in Excel

There is a well-known joke in the IT world – if you have a problem and you try RegEx to solve it, now you have two problems. Still, RegEx in VBA (and thus in Excel) exists as an additional library.

Tagged with: , , ,

VBA – Change Conditional Compilation Arguments in Access

VBA is not a scripting language. It compiles. As such, it has compilation arguments, which can be changed through code or manually. In MS Access you may find these here: VBEditor>Tools>VBA Project>Database Properties: If you want to use them for

Tagged with: , ,

C# – SoftUni – Natural Order Sequences

Another SoftUni algorithm problem that I have considered interesting is presented here: You are given an integer S. Generate all non-empty sequences of numbers in range [1…S], which have sum of elements ≤ S. Display the sequences in their natural order,

Tagged with: , , ,

JavaScript – Simple Progressive Web Application

Tomorrow I will be visiting the HackConf at Sofia, Bulgaria. Thus, today I was part of a workshop for Progressive Web Applications and I will try to summarize how to build an application, which simply displays something like the Facebook

Software Architecture Summit – Hitchhiker’s guide to Architecture Documentation

On Monday, I was at Berlin for the first day of the Software Architecture Summit.  There I took part at the Hitchhiker’s guide to Architecture Documentation workshop. This is the summary of what I learned: Hitchhiker’s Guide to Architecture Documentation The presentation

Tagged with: , , ,

Software Architecture Summit – Diagrams for Modern Software Architecture

Yesterday, I was at Berlin for the first day of the Software Architecture Summit. I have participated on one of the workshops – Diagrams for Modern Software Architecture and I will simply put my notes about it, hoping that it

Tagged with: ,

C# – SoftUni – Bridges – Greed Algorithm

Some days ago I was checking the algorithm problems for the algorith exam preparation of SoftUni and I have decided to solve one problem. The problem is named “Bridges” (hence the youtube link above) and is a nice example of Greed

Tagged with: , ,

C# – CodeForces – Tell Your World

Y = mX+B This formula is the basics of the Cartesian coordinate system. And about 70% of the knowledge, needed to solve problem B in the 2. Division of CodeForces. The problem looks like this: There are n points on a coordinate

Tagged with: , ,

C# – CodeForces – Odds and Ends

The first problem in CodeForces, division 2 is usually an implementation problem. This means that after reading it, a Joe-average algorithmic person would know how to write it in less than 5 minutes. Or so I thought, before seeing this

Tagged with: ,

C# – CodeForces – Two TVs

Having two TVs is great. Or it used to be in the 90s. Anyhow, the latest problem in CodeForces that I have resolved was concerning a guy with a schedule of TV shows, which he was planning to watch on his

Tagged with: , ,

C# – CodeForces – Luba And The Ticket

Magic tickets are considered the tickets in which the sum of the left digits is equal to the sum of the right digits. E.g., if you ticket is number 124016 it is a magic ticket, because 1+2+4 = 0 +

Tagged with: , ,

CodeForces – Game of Rows

CodeForces.com has become something like a hobby – instead of thinking about a topic for an article, I simply solve a problem there and blog about it. Thus, lately I have taken a look at Round 428, Division 2, problem

Tagged with: , , ,

Book Review – Business Intelligence Tools for Small Companies

About a month ago I have received the Business Intelligence Tools for Small Companies book, upon a request from my site to Apress.com. Now, the book is read and I am writing the review. In general, the book starts with

Tagged with: ,

VBA – Listing all procedures in all modules

Sometimes you need to unite two projects into one in VBA. In these two projects, if you are using similar “own built libraries” you are in a kind of trouble. The trouble is called Compile Error :Ambiguous name detected: name Then

Tagged with: , , ,

CodeForces – Star Sky

CodeForces.com is one of the reasons why I blog quite often. Last week, in round 427 there was an interesting problem, which I was eager to solve. The problem was described as follows: The Cartesian coordinate system is set in

Tagged with: ,

PowerPoint VBA – Format All Forms in the active slide

In Powerpoint sometimes it is a bit boring (or challenging), when one has to make the shapes in a presentation the same size and to drag them to the same position. As far as there is no macro recorder there,

Tagged with: , ,
Top