A stack is an Abstract data type?

Hi, hope this is allowed here. I am confused about what it means to call something an abstract data type. What does it mean when a stack is called an Abstract data type.

πŸ‘︎ 10
πŸ’¬︎
πŸ‘€︎ u/Bigdogtrist
πŸ“…︎ Nov 28 2019
🚨︎ report
Abstract Data Types I: The Stack

This is a new series I'm starting, gonna cover Stacks, Bags and Queues using linked lists and arrays then cover sorting algorithms before deciding what to do after that. I'm looking for feedback I know I probably need to flesh out a bit more but I'm not that great of a writer just yet still trying to get that part down (without doing the college style "lets bloat this paper just to reach the word count" and actually have substance.)

I hope I can be of help to someone!

https://discustd.com/Blog/01-Introduction-To-Stacks-In-Java.html

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/KinterVonHurin
πŸ“…︎ Oct 17 2018
🚨︎ report
Abstract Data Types do be making me horny
πŸ‘︎ 30
πŸ’¬︎
πŸ‘€︎ u/SupremusMemus
πŸ“…︎ Jan 05 2022
🚨︎ report
Is it important to know how to make your own abstract data type classes in a career?

I have just finished data structures class and now know how to make linked lists, hash tables and the like

however, at some point in the class, my professor said that C++ (the language the course was taught in) has libraries for all of these ADTs which we can just important in a real world setting

so in an actual career, is being able to create these ADTs important? Or is data structure class just an exercise in learning how they work?

πŸ‘︎ 22
πŸ’¬︎
πŸ“…︎ Nov 05 2021
🚨︎ report
Does Java ArrayList implement an array or list abstract data type?

Watching Georgia Tech 1332 Edx videos.

The first video went over the array ADT, then brought up ArrayLists but said it implements a list ADT. I can't tell the difference between array and list abstract data types. In Python a list can have non-similar elements, but I know for sure an array cannot. I'm not sure if a list can. Judging by the name "arraylist", I'm guessing it implements a mix of both arrays and lists, further implying the two concepts are distinct, but I can't find any text that compares them.

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/fittyfive9
πŸ“…︎ Dec 10 2021
🚨︎ report
Using Abstract Data Types in TLA+ hillelwayne.com/post/tla-…
πŸ‘︎ 4
πŸ’¬︎
πŸ‘€︎ u/Alexander-Ni
πŸ“…︎ Dec 13 2021
🚨︎ report
Proving a function body of an Abstract Data Type

Hello !

I am currently working on the 5th volume of the Software Foundations' texbook on "Verifiable C" in Coq which can be found here.

I am having trouble understanding how to solve:

1 subgoal
Espec : OracleKind
p : val
i : Z
il : list Z
gv : globals
Delta_specs := abbreviate : PTree.t funspec
Delta := abbreviate : tycontext
POSTCONDITION := abbreviate : ret_assert
x, y : val
MORE_COMMANDS := abbreviate : statement
______________________________________(1/1)
semax Delta
  (PROP ( )
   LOCAL (temp _i (Vint (Int.repr i)); temp _q x; gvars gv)
   SEP (malloc_token Ews (Tstruct _stack noattr) p; data_at Ews (Tstruct _stack noattr) y p;
   malloc_token Ews (Tstruct _cons noattr) x; data_at Ews (Tstruct _cons noattr) (Vint (Int.repr i), y) x;
   listrep il y; mem_mgr gv)) (_free([(_q)%expr]);
                               MORE_COMMANDS) POSTCONDITION

My proof looks like this so far:

(** **** Exercise: 2 stars, standard (body_pop) *)
Lemma body_pop: semax_body Vprog Gprog f_pop pop_spec.
Proof.
start_function.
unfold stack in *. Intros x.
forward.
unfold listrep; fold listrep. Intros y.
forward.
forward.
deadvars.
forward. hint.

The last hint gives me this message:

When doing forward_call through this call to _free
you need to supply a WITH-witness of type (type*val*globals) and you need to supply a proof that x
<>nullval.  Look in your SEP clauses for 'data_at _ (Tstruct _cons noattr) _ x ', which will be useful for both.
Regarding the proof, assert_PROP(...) will make use of the fact that data_at cannot be a nullval.
Regarding the witness, you should look at the funspec declared for _free
to see what will be needed; look in Verif_stack.v at free_spec_example.
But in particular, for the type, you can use the second argument of the data_at, that is, 
(Tstruct _cons noattr) .
Regarding the 'globals', you have gv : globals above the line.
THAT WAS NOT A STANDARD VST HINT, IT IS SPECIAL FOR THE VC VOLUME OF SOFTWARE FOUNDATIONS.
STANDARD VST HINTS WOULD BE AS FOLLOWS:

Hint: try 'forward_call x', where x is a value to instantiate the tuple of the function's WITH clause.  If you want more information about the _type_ of the argument that you must supply to forward_call, do 'forward' for information

I tried

... keep reading on reddit ➑

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/TalionZz
πŸ“…︎ May 31 2021
🚨︎ report
What is the difference between an abstract data type and concrete data type data structure?

What is the difference between abstract data type and concrete data type in data structures? It seems like a simple concept, but I am struggling to understand it.

An abstract data type is abstract implementation wise, meaning it can be implemented through various ways to achieves its functionality?

Is a concrete data type data structure a data type that is known to have a set design/implementation and there is really no other way to implement it?

I read online how a stack is an abstract data type. If I want to could I not implement the stack with a queue, which is another abstract data type, or could I implement the stack with a concrete data type such as an array?

Same thing with concrete data types, could I not implement an array with an abstract data type such as a stack?

Could somebody please help clear this confusion up?

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/legionlen545
πŸ“…︎ Dec 06 2020
🚨︎ report
I thought some data abstraction would be nice. Here is List Library. A simple array/stack data type. Suggestions welcome. gist.github.com/2385969
πŸ‘︎ 11
πŸ’¬︎
πŸ‘€︎ u/thebritishguy1
πŸ“…︎ Apr 14 2012
🚨︎ report
Abstract Data Types - Help

I've been reading a bit about data structures and I came across abstract data types. I don't understand the function of abstract data types. I was wondering whether there was a specific ruleset which ADT must adhere to when it goes from point A to point B in a code. If possible can someone explain ADT to me in detail or link me to an intresting article to read regarding data structures and ADT.

πŸ‘︎ 7
πŸ’¬︎
πŸ‘€︎ u/Sakurako-san
πŸ“…︎ Sep 06 2020
🚨︎ report
Question about the naming of ADTs (Abstract Data Types) in functional programming

Take for example this text on Haskell (though ADTs are not exclusive to Haskell.)

>The "algebra" here is "sums" and "products":
>
>"sum" is alternation (A | B, meaning A or B but not both)
>
>"product" is combination (A B, meaning A and B together)

Given that the traditional definition - coming from a basic math background - of a sum means to ADD two terms, it is totally confusing why in functional programming, SUM here is used to define a mutually exclusive , "or ", choice. Can anyone provide insight as to the why?

πŸ‘︎ 9
πŸ’¬︎
πŸ‘€︎ u/El-Kapistan
πŸ“…︎ Jul 05 2021
🚨︎ report
Why aren't abstract data structures already implemented in python?

So, I am starting to learn about stacks and queues etc. but from what I understand you have to write classes for these objects. Since they are so popular, why aren't they already implemented in python? They could write these classes so much better than me and it would be so much more convenient. (I am lazy.)

πŸ‘︎ 136
πŸ’¬︎
πŸ‘€︎ u/Panagiotis2008
πŸ“…︎ Jan 26 2022
🚨︎ report
Best way to apply a decision tree type logic and monte carlo analysis to a low millions data set? (In MS Azure stack)

Hi all,

TLDR, what components in Azure would you apply to do a monte carlo analysis on a low millions data set? Any other tips?

We are going to be analysing some loan portfolios. Probably a few millions loans. For each loan we would apply a sort of decision tree with applied probabilities. e.g. 60% renegotiated, 20% go to foreclosure, 20% go to legal process. There would then another 1 or 2 nodes, so of renegotiated, 50% go to foreclosure. NB that the rules will be actually a little bit more complicated than that in that the probabilities could be affected by other dimensions in the data.

We'd then want to run this through a monte carlo type analysis and record the results. We would likely also want to see the impact of changing the decision trees, effectively running a new monte carlo with some different inputs.

Not sure if this is more of an analytics question than business intelligence, but I've had good answers here before. Question is what is the most effective tool(s) for this kind of analysis.

πŸ‘︎ 8
πŸ’¬︎
πŸ‘€︎ u/Gazpage
πŸ“…︎ Sep 26 2021
🚨︎ report
Searching for a copy of Bjarne Stroustrup's paper Classes: an abstract data type facility for the C language

Does anyone have a copy of the paper from the title? Published 1982, but it isn't on Stroustrup's website, so perhaps a stretch, but are there any copies of this paper in the wild? Presumably this paper covers "C with classes" and early preprocessing of abstract types in C. I'm extremely curious.

πŸ‘︎ 9
πŸ’¬︎
πŸ“…︎ Jul 20 2021
🚨︎ report
Abstract data type libraries

Hi everyone.

I prefer C to C++ for many reasons. What i miss sometime from C++ is STL. i Which libraries do you usually use for not reinventing the wheel very time ? ( I used search.h of posix, libavl and glib but i was just curious if there where popular alternatives )

πŸ‘︎ 6
πŸ’¬︎
πŸ“…︎ May 05 2021
🚨︎ report
What is an intuitive explanation of the distinction between β€œabstract data types” and β€œdata structures”?

I thought they were the same but all the sources I check say there’s a distinction. Yet one site listed queues and stacks as both. Plz halp thx.

πŸ‘︎ 4
πŸ’¬︎
πŸ‘€︎ u/chidedneck
πŸ“…︎ Nov 23 2019
🚨︎ report
Are Abstract Data Types limited to Data Structures only?

Can we only have an abstract data type definition for concrete data structures? I ask because this Wikipedia link says how "This mathematical model contrasts with data structures, which are concrete representations of data, and are the point of view of an implementer, not a user." I thought we can have an ADT for anything, not just a data structure, and do a concrete implementation for it then.

πŸ‘︎ 6
πŸ’¬︎
πŸ‘€︎ u/whitenysherman22
πŸ“…︎ Apr 30 2021
🚨︎ report
ELI5: What is an abstract data type (ADT)?

Is a ADT just: int x = 5;

and why is a Linked List not a ADT?

πŸ‘︎ 96
πŸ’¬︎
πŸ‘€︎ u/pcaly626
πŸ“…︎ May 08 2016
🚨︎ report
What is the difference between an Algebraic Data Type and an Abstract Data Type?

I am struggling to understand the difference between those two concepts. To me they look pretty much the same, AlgDT allow type composition but so do AbsDT right?

For example I can compose ints and chars in an abstract data type:

struct coordinates {
    int x;
    int y;
    char data_point_name[5];
};

One powerful feature of AlgDT that really impressed was that I was able to define the set of natural numbers recursively:

data Nat = Z | S Nat

where Z is 0 and S the successor function. That is something that I could not do using 'struct' but does it make the different between AlgDTs and AbsDTs a fundamental one?

I know that I am confusing something and that there is a flaw in my understanding but I don't know what! Thank you for reading.

πŸ‘︎ 11
πŸ’¬︎
πŸ‘€︎ u/fictiveaaron
πŸ“…︎ Jun 04 2015
🚨︎ report
Abstract Data Types and static variables

Hi,

So I was just reading about Abstract Data Types,and how they can encapsulate your code, but I still haven't really quite understood what the difference would be between an ADT with all its methods, and a static variable that has methods as well used to modify it or access it. Would anyone be so kind as to shine some light on this matter?

Thank you.

πŸ‘︎ 10
πŸ’¬︎
πŸ‘€︎ u/Chacabucogod
πŸ“…︎ Apr 10 2017
🚨︎ report
Data Structures vs Abstract Data Type

So data structures are how you store data and what not. ADTs are how you implement it. Like a list is a data structure. I can treat it like a list, a queue, single linked list, etc. So how I treat is an ADT. So for Arrays, my course says lists, dynamic array. But is an array itself an ADT as well? Just like a list being an ADT and data structure? I don't need to make an ArrayList or dynamic array. I can just treat it like a singular array. Just like I can treat a list as a list rather than single linked list. Maybe I'm confused. Also, why are ArrayList methods already defined but I have to define linked list methods myself?

πŸ‘︎ 16
πŸ’¬︎
πŸ‘€︎ u/abdulahad1234
πŸ“…︎ Oct 28 2020
🚨︎ report
tRPC - an end-to-end type-safe data layer for full-stack TypeScript πŸ§™β€β™‚οΈ trpc.io
πŸ‘︎ 24
πŸ’¬︎
πŸ‘€︎ u/KATT_
πŸ“…︎ Feb 28 2021
🚨︎ report
What is the difference between an abstract data type and concrete data type data structure?

What is the difference between abstract data type and concrete data type in data structures? It seems like a simple concept, but I am struggling to understand it.

An abstract data type is abstract implementation wise, meaning it can be implemented through various ways to achieves its functionality?

Is a concrete data type data structure a data type that is known to have a set design/implementation and there is really no other way to implement it?

I read online how a stack is an abstract data type. If I want to could I not implement the stack with a queue, which is another abstract data type, or could I implement the stack with a concrete data type such as an array?

Same thing with concrete data types, could I not implement an array with an abstract data type such as a stack?

Could somebody please help clear this confusion up?

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/legionlen545
πŸ“…︎ Dec 06 2020
🚨︎ report
Is a LinkedList a Concrete Data type or an Abstract Data Type?

To me there is only one way to implement a linked list with nodes, but some places online say a linked list an abstract data type, I thought it was a concrete data type. Which one would linked list be as a data structure?

πŸ‘︎ 4
πŸ’¬︎
πŸ‘€︎ u/CrazyLock6
πŸ“…︎ Dec 07 2020
🚨︎ report

Please note that this site uses cookies to personalise content and adverts, to provide social media features, and to analyse web traffic. Click here for more information.