public class PaginatedList<T> : List<T>
{
public int PageIndex { get; private set; }
public int TotalPages { get; private set; }
public PaginatedList(List<T> items, int count, int pageIndex, int pageSize)
{
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Data; | |
using System.Data.SqlClient; | |
using System.Linq; | |
using System.Web; | |
namespace Connection_Class | |
{ | |
public class Connection_Query |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Temp{ | |
public: | |
Delete() | |
{ | |
char a[100],st1[100]; | |
int r=0,i=0; | |
cout<<"Enter a String"<<endl; | |
cin>>a; | |
int loc; | |
cout<<"Enter initial position"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<iostream.h> | |
#include<conio.h> | |
class Temp{ | |
public: | |
Length(char a[]) | |
{ int len=0; | |
for(int i=0; a[i]!='\0'; i++) | |
{ | |
len=len+1; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<iostream.h> | |
#include<conio.h> | |
void main() | |
{ | |
int location=-1,item; | |
int arr[9]; | |
cout<<"Enter the Data"; | |
for(int i=0; i<=9;i++) | |
{ | |
cin>>arr[i]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
a console-based application for school teachers. | |
This application will auto generate questions for Grades 1, 2, 3, 4 and 5. | |
Using this application teacher will be able to give different paper to each student |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import random | |
Comp_guess_number = random.randint(1,5) | |
total_number_of_Attempts = 3 | |
cuurent_attempt =1 | |
while(cuurent_attempt<=total_number_of_Attempts): | |
if cuurent_attempt == total_number_of_Attempts: | |
print("This is last attempt") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*Check Attribute name availablity*/ | |
SELECT TABLE_NAME FROM DataBaseName_Here.INFORMATION_SCHEMA.COLUMNS WHERE COLUMN_NAME = ‘Name' | |
--To check all the tables available in the Database | |
SELECT TABLE_NAME, TABLE_TYPE FROM DataBaseName_Here.INFORMATION_SCHEMA.TABLES ORDER BY TABLE_NAME | |
--To Get the list of columns | |
SELECT COLUMN_NAME FROM DataBaseName_Here.INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME = 'Table Name here' | |
/*Queries to get all the data*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
String[] requestedColumns = { CallLog.Calls.CACHED_NUMBER_LABEL, CallLog.Calls.DURATION }; | |
Cursor calls = managedQuery( CallLog.Calls.CONTENT_URI, requestedColumns, | |
CallLog.Calls.CACHED_NUMBER_LABEL+ " = ?", new String[] { "HourlyClient123" } , null); | |
Log.d(DEBUG_TAG, "Call count: " + calls.getCount()); | |
int durIdx = calls.getColumnIndex(CallLog.Calls.DURATION); | |
int totalDuration = 0; | |
calls.moveToFirst(); | |
while (!calls.isAfterLast()) | |
{ | |
Log.d(DEBUG_TAG, "Duration: " + calls.getInt(durIdx)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<iostream> | |
using namespace std; | |
class Animal | |
{ | |
public: | |
virtual void Sound() | |
{ | |
//No code. . . | |
} |
OlderNewer