Functional operator overloading

why cant we overload [ ] operator instead of the ( ) operator.

@gauravlodhi21 functors are c++ classes that act as functions, and the way to call a function is through () operator. You can try overloading the [] operator too, but that’s not the convention.