15,897,718 members
Sign in
Sign in
Email
Password
Forgot your password?
Sign in with
home
articles
Browse Topics
>
Latest Articles
Top Articles
Posting/Update Guidelines
Article Help Forum
Submit an article or tip
Import GitHub Project
Import your Blog
quick answers
Q&A
Ask a Question
View Unanswered Questions
View All Questions
View C# questions
View C++ questions
View Javascript questions
View Visual Basic questions
View Python questions
discussions
forums
CodeProject.AI Server
All Message Boards...
Application Lifecycle
>
Running a Business
Sales / Marketing
Collaboration / Beta Testing
Work Issues
Design and Architecture
Artificial Intelligence
ASP.NET
JavaScript
Internet of Things
C / C++ / MFC
>
ATL / WTL / STL
Managed C++/CLI
C#
Free Tools
Objective-C and Swift
Database
Hardware & Devices
>
System Admin
Hosting and Servers
Java
Linux Programming
Python
.NET (Core and Framework)
Android
iOS
Mobile
WPF
Visual Basic
Web Development
Site Bugs / Suggestions
Spam and Abuse Watch
features
features
Competitions
News
The Insider Newsletter
The Daily Build Newsletter
Newsletter archive
Surveys
CodeProject Stuff
community
lounge
Who's Who
Most Valuable Professionals
The Lounge
The CodeProject Blog
Where I Am: Member Photos
The Insider News
The Weird & The Wonderful
help
?
What is 'CodeProject'?
General FAQ
Ask a Question
Bugs and Suggestions
Article Help Forum
About Us
Search within:
Articles
Quick Answers
Messages
Comments by Black Mamba Elapidae (Top 24 by date)
Black Mamba Elapidae
8-May-22 10:08am
View
@OriginalGriff : Thank you for your time to comment here. Sorry for just writing my assumption and not the thought process behind it, I have updated comment below question to explain it.
Lastly, No, I dont get paid for calculating complexity of simple code and also this is not related academic homework... I am trying to learn complexity as it is widely asked in interviews and I am just practicing it for common code I normally write.. I already did lot of google search before posting question here... And my question was more of a “yes” “no” type, as I already wrote my assumption on answer and just asked if its correct or not.. never asked for step by step answer! Also I saw article link you posted and didn’t find it relevant. If you still feel this question does not deserve answer then you can ignore it :)
Black Mamba Elapidae
8-May-22 9:58am
View
Deleted
My assumption is,
Time complexity o(n^2) : As filter will be o(n) and inside filter indexOf is used that’s another o(n) making total o(n^2)
But as filter and indexOf is on different arrays, should we say o(n*m) or o(n^2) is fine?
and space complexity o(n) -> as I assumed onlys space required is to store 2 arrays and function. Inside function nothing is stored its just returning results. Will it be right to say o(n) fir 2 arrays and one function?
Black Mamba Elapidae
14-Feb-16 23:20pm
View
I am not sure what are you suggesting with server push.. Please refer my comment on main thread ..
Black Mamba Elapidae
14-Feb-16 23:14pm
View
I know it is a bad idea . But as I mentioned already website B is not in my control and it is already designed to work in this way. this site B can be opened with HttpPost with some json data. user is supposed to select data in site B and it will send that data to site A (target url is already sent in initial request json)
Black Mamba Elapidae
12-Feb-16 5:50am
View
Thanks for quick response.
The website B I am mentioning is a courier website and they post the selected data on exposed url, that is how application B is calling action method of my application . :)
Black Mamba Elapidae
22-Sep-15 8:10am
View
Thanks for explaining it nicely with example :)
Black Mamba Elapidae
22-Sep-15 6:01am
View
Thanks a lot !! I will follow your approach , Please correct me if I am wrong,
With the status(whether it is returning RedirectToAction/json/View/Partial View)
I will also need different data(as for returning View I will need Viewname and model name, for redirect to action I will need controller name action method name etc)
I will be creating a class which will hold a status and respective data like:
Status = RedirectToAction/json/View/Partial View
and Different data depending on status,
- My buisness logic function will return the object of above mentioned class
- and depending on the status of that object and data I will redirect from controller
Black Mamba Elapidae
20-Sep-15 23:52pm
View
Hey thanks for your answer, Code I have posted in the question is just the pattern of my controllers. Please refer comment I have posted on F-ES Sitecore's answer below , and Please suggest me the right approach
Black Mamba Elapidae
20-Sep-15 23:50pm
View
Thanks for your answer,But I have posted simplified version of my code.. In every loop my actual code is also doing some other things with redirect to action. and I cant just remove that much code and move it to business logic because it comes with the redirect to action at the end of the loop..
So my question is what do you recommend , Should I keep all that code there in the controller ? Or call different business logic function in every loop ? Or use the approach I have mentioned in the question???
Black Mamba Elapidae
4-Sep-15 6:20am
View
Please help :(
Black Mamba Elapidae
24-Aug-15 5:44am
View
Then if its a list and suppose it has no elements and you try to find out its length then it will ofcourse throw an exception . One thing you can do is calculate its length in js itself(also add extra check to calculate length only when navigation list is not null !) and then bind this new variable in template
Black Mamba Elapidae
24-Aug-15 5:32am
View
They are not just comments :P It is called as Knockout containerless control flow syntax.. You can find more about it here, http://knockoutjs.com/documentation/if-binding.html
Black Mamba Elapidae
22-Aug-15 8:05am
View
Impressive answer!! Well said :)
Black Mamba Elapidae
22-Aug-15 7:01am
View
Can you share the code of what you have tried, calculations are not at all difficult you know! :)
Black Mamba Elapidae
21-Aug-15 2:52am
View
Why !!
Black Mamba Elapidae
20-Aug-15 6:58am
View
What is Navigations in containerModel().QlikViewData.Navigations.length ???
I cant see any 'Navigations' in your viewmodel ! Can you please elaborate On what condition you want to make that div visible ??
Black Mamba Elapidae
20-Aug-15 6:44am
View
Cant you just do something like mainView.containerModel.Employee(result.Employee) ????
Black Mamba Elapidae
20-Aug-15 4:59am
View
From where you want to generate values in XML tags?? Example: you have mention "Test Data" in txtName xml tag, Is this something inputted in UI???
Black Mamba Elapidae
17-Aug-15 5:25am
View
have you used !isPostBack ?? Because Code you have posted in question looks fine.
Looks like you are resetting values somehow. Add check "!isPostBack" before binding data to gridview . this should work. If not can you share code of submit button and page_Load()
Black Mamba Elapidae
17-Aug-15 2:20am
View
just update the <form> in your question
Black Mamba Elapidae
17-Aug-15 2:20am
View
Deleted
Just update the <form> in your question
Black Mamba Elapidae
17-Aug-15 2:03am
View
Please post the code where you are calling js function btnExternalPayGhest_Click(id).
Black Mamba Elapidae
17-Aug-15 1:57am
View
Hey, what do you mean by "..but the main issue is it shows that none of the check box is checked..", Does that means when you debug the code , you never enter in, " if (chk.Checked) { }" loop ???
Because when I wrote a simpler form of your code(i.e same UI just simpler code behind) I was able to get inside the loop.
Black Mamba Elapidae
17-Aug-15 1:21am
View
How are you calling btnExternalPayGhest_Click(id)?? have you checked by adding debugger on js , if all the values are available in function btnExternalPayGhest_Click(id) . Because location.href should work fine . And also on which browser are you testing this code.
Show More